Search Options

Results per page
Sort
Preferred Languages
Advance

Results 261 - 270 of 850 for pydantic (0.07 sec)

  1. tests/test_filter_pydantic_sub_model_pv2.py

    from fastapi.exceptions import ResponseValidationError
    from fastapi.testclient import TestClient
    
    from .utils import needs_pydanticv2
    
    
    @pytest.fixture(name="client")
    def get_client():
        from pydantic import BaseModel, ValidationInfo, field_validator
    
        app = FastAPI()
    
        class ModelB(BaseModel):
            username: str
    
        class ModelC(ModelB):
            password: str
    
        class ModelA(BaseModel):
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Thu Apr 18 19:40:57 UTC 2024
    - 6.3K bytes
    - Viewed (0)
  2. tests/test_tutorial/test_request_files/test_tutorial001_02_py310.py

                                        }
                                    )
                                    | IsDict(
                                        # TODO: remove when deprecating Pydantic v1
                                        {
                                            "$ref": "#/components/schemas/Body_create_file_files__post"
                                        }
                                    )
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri Jul 07 17:12:13 UTC 2023
    - 8.5K bytes
    - Viewed (0)
  3. tests/test_tutorial/test_dependencies/test_tutorial012.py

                        "msg": "Field required",
                        "input": None,
                    },
                ]
            }
        ) | IsDict(
            # TODO: remove when deprecating Pydantic v1
            {
                "detail": [
                    {
                        "loc": ["header", "x-token"],
                        "msg": "field required",
                        "type": "value_error.missing",
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Thu Apr 18 19:40:57 UTC 2024
    - 8.4K bytes
    - Viewed (0)
  4. docs/em/docs/tutorial/path-params.md

    <img src="/img/tutorial/path-params/image02.png">
    
    ๐ŸŽ ๐ŸŒŒ, ๐Ÿ“ค ๐Ÿ“š ๐Ÿ”— ๐Ÿงฐ. โœ… ๐Ÿ“Ÿ โšก ๐Ÿงฐ ๐Ÿ“š ๐Ÿ‡ช๐Ÿ‡ธ.
    
    ## Pydantic
    
    ๐ŸŒ ๐Ÿ’ฝ ๐Ÿ”ฌ ๐ŸŽญ ๐Ÿ”ฝ ๐Ÿš˜ <a href="https://docs.pydantic.dev/" class="external-link" target="_blank">Pydantic</a>, ๐Ÿ‘† ๐Ÿคš ๐ŸŒ ๐Ÿ’ฐ โšช๏ธโžก๏ธ โšซ๏ธ. &amp; ๐Ÿ‘† ๐Ÿ’ญ ๐Ÿ‘† ๐Ÿ‘ โœ‹.
    
    ๐Ÿ‘† ๐Ÿ’ช โš™๏ธ ๐ŸŽ ๐Ÿ†Ž ๐Ÿ“„ โฎ๏ธ `str`, `float`, `bool` &amp; ๐Ÿ“š ๐ŸŽ ๐Ÿ— ๐Ÿ“Š ๐Ÿ†Ž.
    
    ๐Ÿ“š ๐Ÿ‘ซ ๐Ÿ”ฌ โญ ๐Ÿ“ƒ ๐Ÿ”ฐ.
    
    ## โœ” ๐Ÿค”
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 7.7K bytes
    - Viewed (0)
  5. docs/ru/docs/index.md

    ## ะ—ะฐะฒะธัะธะผะพัั‚ะธ
    
    FastAPI ัั‚ะพะธั‚ ะฝะฐ ะฟะปะตั‡ะฐั… ะณะธะณะฐะฝั‚ะพะฒ:
    
    * <a href="https://www.starlette.io/" class="external-link" target="_blank">Starlette</a> ะดะปั ั‡ะฐัั‚ะธ ัะฒัะทะฐะฝะฝะพะน ั ะฒะตะฑะพะผ.
    * <a href="https://docs.pydantic.dev/" class="external-link" target="_blank">Pydantic</a> ะดะปั ั‡ะฐัั‚ะธ ัะฒัะทะฐะฝะฝะพะน ั ะดะฐะฝะฝั‹ะผะธ.
    
    ## ะฃัั‚ะฐะฝะพะฒะบะฐ
    
    <div class="termy">
    
    ```console
    $ pip install fastapi
    
    ---> 100%
    ```
    
    </div>
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 20 19:20:23 UTC 2024
    - 25.8K bytes
    - Viewed (0)
  6. docs/ko/docs/tutorial/security/get-current-user.md

    ```
    
    ////
    
    //// tab | ํŒŒ์ด์ฌ 3.10 ์ด์ƒ
    
    ```Python hl_lines="29"
    {!> ../../docs_src/security/tutorial002_py310.py!}
    ```
    
    ////
    
    Pydantic ๋ชจ๋ธ์ธ `User`๋กœ `current_user`์˜ ํƒ€์ž…์„ ์„ ์–ธํ•˜๋Š” ๊ฒƒ์„ ์•Œ์•„์•ผ ํ•ฉ๋‹ˆ๋‹ค.
    
    ์ด๊ฒƒ์€ ๋ชจ๋“  ์™„๋ฃŒ ๋ฐ ํƒ€์ž… ๊ฒ€์‚ฌ๋ฅผ ํ†ตํ•ด ํ•จ์ˆ˜ ๋‚ด๋ถ€์—์„œ ์šฐ๋ฆฌ๋ฅผ ๋„์šธ ๊ฒƒ์ž…๋‹ˆ๋‹ค.
    
    /// tip | "ํŒ"
    
    ์š”์ฒญ ๋ณธ๋ฌธ๋„ Pydantic ๋ชจ๋ธ๋กœ ์„ ์–ธ๋œ๋‹ค๋Š” ๊ฒƒ์„ ๊ธฐ์–ตํ•  ๊ฒƒ์ž…๋‹ˆ๋‹ค.
    
    ์—ฌ๊ธฐ์„œ **FastAPI**๋Š” `Depends`๋ฅผ ์‚ฌ์šฉํ•˜๊ณ  ์žˆ๊ธฐ ๋•Œ๋ฌธ์— ํ˜ผ๋™๋˜์ง€ ์•Š์Šต๋‹ˆ๋‹ค.
    
    ///
    
    /// check | "ํ™•์ธ"
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 5.6K bytes
    - Viewed (0)
  7. docs/ja/docs/tutorial/body-updates.md

    `PATCH`ใฏ`PUT`ใ‚ˆใ‚Šใ‚‚ใ‚ใพใ‚Šไฝฟใ‚ใ‚ŒใฆใŠใ‚‰ใšใ€็Ÿฅใ‚‰ใ‚Œใฆใ„ใพใ›ใ‚“ใ€‚
    
    ใพใŸใ€ๅคšใใฎใƒใƒผใƒ ใฏ้ƒจๅˆ†็š„ใชๆ›ดๆ–ฐใงใ‚ใฃใฆใ‚‚`PUT`ใ ใ‘ใ‚’ไฝฟ็”จใ—ใฆใ„ใพใ™ใ€‚
    
    **FastAPI** ใฏใฉใ‚“ใชๅˆถ้™ใ‚‚่ชฒใ‘ใฆใ„ใชใ„ใฎใงใ€ใใ‚Œใ‚‰ใ‚’ไฝฟใ†ใฎใฏ **่‡ช็”ฑ** ใงใ™ใ€‚
    
    ใ—ใ‹ใ—ใ€ใ“ใฎใ‚ฌใ‚คใƒ‰ใงใฏใ€ใใ‚Œใ‚‰ใŒใฉใฎใ‚ˆใ†ใซไฝฟ็”จใ•ใ‚Œใ‚‹ใ“ใจใ‚’ๆ„ๅ›ณใ—ใฆใ„ใ‚‹ใ‹ใ‚’ๅคšใ‹ใ‚Œๅฐ‘ใชใ‹ใ‚Œใ€็คบใ—ใฆใ„ใพใ™ใ€‚
    
    ///
    
    ### Pydanticใฎ`exclude_unset`ใƒ‘ใƒฉใƒกใƒผใ‚ฟใฎไฝฟ็”จ
    
    ้ƒจๅˆ†็š„ใชๆ›ดๆ–ฐใ‚’ๅ—ใ‘ๅ–ใ‚ŠใŸใ„ๅ ดๅˆใฏใ€Pydanticใƒขใƒ‡ใƒซใฎ`.dict()`ใฎ`exclude_unset`ใƒ‘ใƒฉใƒกใƒผใ‚ฟใ‚’ไฝฟ็”จใ™ใ‚‹ใจ้žๅธธใซไพฟๅˆฉใงใ™ใ€‚
    
    `item.dict(exclude_unset=True)`ใฎใ‚ˆใ†ใซใ€‚
    
    ใ“ใ‚Œใซใ‚ˆใ‚Šใ€`item`ใƒขใƒ‡ใƒซใฎไฝœๆˆๆ™‚ใซ่จญๅฎšใ•ใ‚ŒใŸใƒ‡ใƒผใ‚ฟใฎใฟใ‚’ๆŒใค`dict`ใŒ็”Ÿๆˆใ•ใ‚Œใ€ใƒ‡ใƒ•ใ‚ฉใƒซใƒˆๅ€คใฏ้™คๅค–ใ•ใ‚Œใพใ™ใ€‚
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 5.1K bytes
    - Viewed (0)
  8. tests/test_tutorial/test_security/test_tutorial005_an_py310.py

                        "title": "User",
                        "required": IsOneOf(
                            ["username", "email", "full_name", "disabled"],
                            # TODO: remove when deprecating Pydantic v1
                            ["username"],
                        ),
                        "type": "object",
                        "properties": {
                            "username": {"title": "Username", "type": "string"},
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Wed Mar 13 19:07:10 UTC 2024
    - 16.3K bytes
    - Viewed (0)
  9. tests/test_tutorial/test_sql_databases/test_tutorial002.py

        )
    
        with TestClient(mod.app) as c:
            yield c
    
    
    def test_crud_app(client: TestClient):
        # TODO: this warns that SQLModel.from_orm is deprecated in Pydantic v1, refactor
        # this if using obj.model_validate becomes independent of Pydantic v2
        with warnings.catch_warnings(record=True):
            warnings.simplefilter("always")
            # No heroes before creating
            response = client.get("heroes/")
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Wed Oct 09 19:44:42 UTC 2024
    - 19.9K bytes
    - Viewed (0)
  10. docs/de/docs/how-to/separate-openapi-schemas.md

    Bei Verwendung von **Pydantic v2** ist die generierte OpenAPI etwas genauer und **korrekter** als zuvor. ๐Ÿ˜Ž
    
    Tatsรคchlich gibt es in einigen Fรคllen sogar **zwei JSON-Schemas** in OpenAPI fรผr dasselbe Pydantic-Modell fรผr Eingabe und Ausgabe, je nachdem, ob sie **Defaultwerte** haben.
    
    Sehen wir uns an, wie das funktioniert und wie Sie es bei Bedarf รคndern kรถnnen.
    
    ## Pydantic-Modelle fรผr Eingabe und Ausgabe
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 7K bytes
    - Viewed (0)
Back to top