Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 84 for has (0.5 sec)

  1. docs/en/docs/tutorial/body-nested-models.md

        {!> ../../../docs_src/body_nested_models/tutorial001.py!}
        ```
    
    This will make `tags` be a list, although it doesn't declare the type of the elements of the list.
    
    ## List fields with type parameter
    
    But Python has a specific way to declare lists with internal types, or "type parameters":
    
    ### Import typing's `List`
    
    In Python 3.9 and above you can use the standard `list` to declare these type annotations as we'll see below. 💡
    
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Fri Mar 22 01:42:11 GMT 2024
    - 9.5K bytes
    - Viewed (0)
  2. docs/en/docs/tutorial/request-files.md

        !!! tip
            Prefer to use the `Annotated` version if possible.
    
        ```Python hl_lines="12"
        {!> ../../../docs_src/request_files/tutorial001.py!}
        ```
    
    Using `UploadFile` has several advantages over `bytes`:
    
    * You don't have to use `File()` in the default value of the parameter.
    * It uses a "spooled" file:
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Wed Mar 13 19:02:19 GMT 2024
    - 10.2K bytes
    - Viewed (0)
  3. docs_src/query_params/tutorial003.py

        item = {"item_id": item_id}
        if q:
            item.update({"q": q})
        if not short:
            item.update(
                {"description": "This is an amazing item that has a long description"}
            )
    Python
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Sat May 14 11:59:59 GMT 2022
    - 406 bytes
    - Viewed (0)
  4. docs_src/query_params/tutorial004_py310.py

    ):
        item = {"item_id": item_id, "owner_id": user_id}
        if q:
            item.update({"q": q})
        if not short:
            item.update(
                {"description": "This is an amazing item that has a long description"}
            )
    Python
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Fri Jan 07 14:11:31 GMT 2022
    - 436 bytes
    - Viewed (0)
  5. docs/en/docs/async.md

    Asynchronous code just means that the language 💬 has a way to tell the computer / program 🤖 that at some point in the code, it 🤖 will have to wait for *something else* to finish somewhere else. Let's say that *something else* is called "slow-file" 📝.
    
    So, during that time, the computer can go and do some other work, while "slow-file" 📝 finishes.
    
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Thu Apr 18 19:53:19 GMT 2024
    - 23K bytes
    - Viewed (0)
  6. docs/en/docs/advanced/security/oauth2-scopes.md

    * The *path operation* `read_own_items` has:
        * Required scopes `["items"]` with the dependency:
        * `get_current_active_user`:
            *  The dependency function `get_current_active_user` has:
                * Required scopes `["me"]` with the dependency:
                * `get_current_user`:
                    * The dependency function `get_current_user` has:
                        * No scopes required by itself.
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Thu Jan 11 21:21:35 GMT 2024
    - 20.5K bytes
    - Viewed (0)
  7. docs/en/docs/how-to/extending-openapi.md

    There are some cases where you might need to modify the generated OpenAPI schema.
    
    In this section you will see how.
    
    ## The normal process
    
    The normal (default) process, is as follows.
    
    A `FastAPI` application (instance) has an `.openapi()` method that is expected to return the OpenAPI schema.
    
    As part of the application object creation, a *path operation* for `/openapi.json` (or for whatever you set your `openapi_url`) is registered.
    
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Sat Aug 19 19:54:04 GMT 2023
    - 3.2K bytes
    - Viewed (0)
  8. docs/en/docs/how-to/sql-databases-peewee.md

    ### Context variables
    
    Python 3.7 has <a href="https://docs.python.org/3/library/contextvars.html" class="external-link" target="_blank">`contextvars`</a> that can create a local variable very similar to `threading.local`, but also supporting these async features.
    
    There are several things to keep in mind.
    
    The `ContextVar` has to be created at the top of the module, like:
    
    ```Python
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Tue Jan 16 13:23:25 GMT 2024
    - 23.6K bytes
    - Viewed (0)
  9. fastapi/concurrency.py

        cm: ContextManager[_T],
    ) -> AsyncGenerator[_T, None]:
        # blocking __exit__ from running waiting on a free thread
        # can create race conditions/deadlocks if the context manager itself
        # has its own internal pool (e.g. a database connection pool)
        # to avoid this we let __exit__ run without a capacity limit
        # since we're creating a new limiter for each call, any non-zero limit
        # works (1 is arbitrary)
    Python
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Mon Dec 25 17:57:35 GMT 2023
    - 1.4K bytes
    - Viewed (0)
  10. docs/en/docs/help-fastapi.md

    By adding a star, other users will be able to find it more easily and see that it has been already useful for others.
    
    ## Watch the GitHub repository for releases
    
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Thu Apr 18 19:53:19 GMT 2024
    - 13.7K bytes
    - Viewed (0)
Back to top