Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 31 for Potter (0.16 sec)

  1. docs/en/docs/advanced/additional-responses.md

                    * **FastAPI** adds a reference here to the global JSON Schemas in another place in your OpenAPI instead of including it directly. This way, other applications and clients can use those JSON Schemas directly, provide better code generation tools, etc.
    
    The generated responses in the OpenAPI for this *path operation* will be:
    
    ```JSON hl_lines="3-12"
    {
        "responses": {
            "404": {
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Jan 11 16:31:18 GMT 2024
    - 8.8K bytes
    - Viewed (0)
  2. docs/en/docs/how-to/separate-openapi-schemas.md

    </div>
    
    With this feature from **Pydantic v2**, your API documentation is more **precise**, and if you have autogenerated clients and SDKs, they will be more precise too, with a better **developer experience** and consistency. 🎉
    
    ## Do not Separate Schemas
    
    Now, there are some cases where you might want to have the **same schema for input and output**.
    
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Tue Oct 17 05:59:11 GMT 2023
    - 6.7K bytes
    - Viewed (0)
  3. docs/pt/docs/python-types.md

    * `float`
    * `bool`
    * `bytes`
    
    ```Python hl_lines="1"
    {!../../../docs_src/python_types/tutorial005.py!}
    ```
    
    ### Tipos genéricos com parâmetros de tipo
    
    Existem algumas estruturas de dados que podem conter outros valores, como `dict`, `list`, `set` e `tuple`. E os valores internos também podem ter seu próprio tipo.
    
    Para declarar esses tipos e os tipos internos, você pode usar o módulo Python padrão `typing`.
    
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Fri Mar 22 01:42:11 GMT 2024
    - 9.6K bytes
    - Viewed (0)
  4. docs/en/docs/tutorial/path-params-numeric-validations.md

    Python will complain if you put a value with a "default" before a value that doesn't have a "default".
    
    But you can re-order them, and have the value without a default (the query parameter `q`) first.
    
    It doesn't matter for **FastAPI**. It will detect the parameters by their names, types and default declarations (`Query`, `Path`, etc), it doesn't care about the order.
    
    So, you can declare your function as:
    
    === "Python 3.8 non-Annotated"
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Jan 11 16:31:18 GMT 2024
    - 9.1K bytes
    - Viewed (0)
  5. docs/en/docs/advanced/index.md

    Or it might be the case that you just prefer to take other courses because they adapt better to your learning style.
    
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sun Mar 31 23:52:53 GMT 2024
    - 1.8K bytes
    - Viewed (0)
  6. docs/pt/docs/tutorial/schema-extra-example.md

    As chaves do `dict` identificam cada exemplo, e cada valor é outro `dict`.
    
    Cada `dict` de exemplo específico em `examples` pode conter:
    
    * `summary`: Pequena descrição do exemplo.
    * `description`: Uma descrição longa que pode conter texto em Markdown.
    * `value`: O próprio exemplo mostrado, ex: um `dict`.
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Fri Mar 22 01:42:11 GMT 2024
    - 6.1K bytes
    - Viewed (0)
  7. tests/test_empty_router.py

    import pytest
    from fastapi import APIRouter, FastAPI
    from fastapi.exceptions import FastAPIError
    from fastapi.testclient import TestClient
    
    app = FastAPI()
    
    router = APIRouter()
    
    
    @router.get("")
    def get_empty():
        return ["OK"]
    
    
    app.include_router(router, prefix="/prefix")
    
    
    client = TestClient(app)
    
    
    def test_use_empty():
        with client:
            response = client.get("/prefix")
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sun Jun 11 22:37:34 GMT 2023
    - 805 bytes
    - Viewed (0)
  8. tests/test_router_events.py

        @sub_router.on_event("shutdown")
        def sub_router_shutdown() -> None:
            state.sub_router_shutdown = True
    
        router.include_router(sub_router)
        app.include_router(router)
    
        assert state.app_startup is False
        assert state.router_startup is False
        assert state.sub_router_startup is False
        assert state.app_shutdown is False
        assert state.router_shutdown is False
        assert state.sub_router_shutdown is False
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Wed Oct 18 12:36:40 GMT 2023
    - 3.2K bytes
    - Viewed (0)
  9. docs_src/sql_databases_peewee/sql_app/schemas.py

        class Config:
            orm_mode = True
            getter_dict = PeeweeGetterDict
    
    
    class UserBase(BaseModel):
        email: str
    
    
    class UserCreate(UserBase):
        password: str
    
    
    class User(UserBase):
        id: int
        is_active: bool
        items: List[Item] = []
    
        class Config:
            orm_mode = True
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sat May 14 11:59:59 GMT 2022
    - 868 bytes
    - Viewed (0)
  10. docs/pt/docs/benchmarks.md

    * **Uvicorn**:
        * Terá a melhor performance, já que ele não tem muito código extra além do servidor em si.
        * Você não conseguiria escrever uma aplicação em Uvicorn diretamente. Isso significa que seu código deveria conter, mais ou menos, todo o código fornecido pelo Starlette (ou **FastAPI**). E se você fizesse isso, sua aplicação final poderia ter a mesma sobrecarga que utilizar um _framework_ que minimiza o código e _bugs_ da sua aplicação.
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu May 12 00:06:16 GMT 2022
    - 3.9K bytes
    - Viewed (0)
Back to top