Search Options

Display Count
Sort
Preferred Language
Advanced Search

Results 231 - 240 of 1,471 for nine (0.09 seconds)

  1. docs_src/header_param_models/tutorial003_an_py39.py

    from fastapi import FastAPI, Header
    from pydantic import BaseModel
    
    app = FastAPI()
    
    
    class CommonHeaders(BaseModel):
        host: str
        save_data: bool
        if_modified_since: Union[str, None] = None
        traceparent: Union[str, None] = None
        x_tag: list[str] = []
    
    
    @app.get("/items/")
    async def read_items(
        headers: Annotated[CommonHeaders, Header(convert_underscores=False)],
    ):
    Created: Sun Dec 28 07:19:09 GMT 2025
    - Last Modified: Sun Mar 23 20:48:54 GMT 2025
    - 443 bytes
    - Click Count (0)
  2. docs_src/body_nested_models/tutorial003_py39.py

    from typing import Union
    
    from fastapi import FastAPI
    from pydantic import BaseModel
    
    app = FastAPI()
    
    
    class Item(BaseModel):
        name: str
        description: Union[str, None] = None
        price: float
        tax: Union[float, None] = None
        tags: set[str] = set()
    
    
    @app.put("/items/{item_id}")
    async def update_item(item_id: int, item: Item):
        results = {"item_id": item_id, "item": item}
    Created: Sun Dec 28 07:19:09 GMT 2025
    - Last Modified: Sat May 14 11:59:59 GMT 2022
    - 409 bytes
    - Click Count (0)
  3. ci/official/containers/ml_build/cuda12.1_cudnn9.8.packages.txt

    # All required CUDA packages
    cuda-compat-12-1
    cuda-command-line-tools-12-1
    cuda-cudart-dev-12-1
    cuda-nvcc-12-1
    cuda-cupti-12-1
    cuda-nvprune-12-1
    cuda-libraries-12-1
    cuda-libraries-dev-12-1
    cuda-nvml-dev-12-1
    libcufft-12-1
    libcurand-12-1
    libcusolver-dev-12-1
    libcusparse-dev-12-1
    libcublas-12-1
    libcublas-dev-12-1
    libnccl-dev=2.18.3-1+cuda12.1
    libnccl2=2.18.3-1+cuda12.1
    Created: Tue Dec 30 12:39:10 GMT 2025
    - Last Modified: Fri Mar 21 01:02:41 GMT 2025
    - 534 bytes
    - Click Count (0)
  4. ci/official/containers/ml_build/cuda12.3_cudnn9.1.packages.txt

    # All required CUDA packages
    cuda-compat-12-3
    cuda-command-line-tools-12-3
    cuda-cudart-dev-12-3
    cuda-nvcc-12-3
    cuda-cupti-12-3
    cuda-nvprune-12-3
    cuda-libraries-12-3
    cuda-libraries-dev-12-3
    cuda-nvml-dev-12-3
    libcufft-12-3
    libcurand-12-3
    libcusolver-dev-12-3
    libcusparse-dev-12-3
    libcublas-12-3
    libcublas-dev-12-3
    libnccl-dev=2.19.3-1+cuda12.3
    libnccl2=2.19.3-1+cuda12.3
    Created: Tue Dec 30 12:39:10 GMT 2025
    - Last Modified: Tue Feb 18 20:42:21 GMT 2025
    - 535 bytes
    - Click Count (3)
  5. docs/de/docs/advanced/response-cookies.md

    Sie können den `Response`-Parameter auch in Abhängigkeiten deklarieren und darin Cookies (und Header) setzen.
    
    ## Eine `Response` direkt zurückgeben { #return-a-response-directly }
    
    Sie können Cookies auch erstellen, wenn Sie eine `Response` direkt in Ihrem Code zurückgeben.
    
    Dazu können Sie eine Response erstellen, wie unter [Eine Response direkt zurückgeben](response-directly.md){.internal-link target=_blank} beschrieben.
    
    Created: Sun Dec 28 07:19:09 GMT 2025
    - Last Modified: Wed Dec 17 20:41:43 GMT 2025
    - 2.7K bytes
    - Click Count (0)
  6. docs_src/dataclasses_/tutorial002_py310.py

    from dataclasses import dataclass, field
    
    from fastapi import FastAPI
    
    
    @dataclass
    class Item:
        name: str
        price: float
        tags: list[str] = field(default_factory=list)
        description: str | None = None
        tax: float | None = None
    
    
    app = FastAPI()
    
    
    @app.get("/items/next", response_model=Item)
    async def read_next_item():
        return {
            "name": "Island In The Moon",
            "price": 12.99,
    Created: Sun Dec 28 07:19:09 GMT 2025
    - Last Modified: Fri Dec 26 10:43:02 GMT 2025
    - 506 bytes
    - Click Count (0)
  7. docs_src/body_fields/tutorial001_py310.py

    from pydantic import BaseModel, Field
    
    app = FastAPI()
    
    
    class Item(BaseModel):
        name: str
        description: str | None = Field(
            default=None, title="The description of the item", max_length=300
        )
        price: float = Field(gt=0, description="The price must be greater than zero")
        tax: float | None = None
    
    
    @app.put("/items/{item_id}")
    async def update_item(item_id: int, item: Item = Body(embed=True)):
    Created: Sun Dec 28 07:19:09 GMT 2025
    - Last Modified: Fri May 13 23:38:22 GMT 2022
    - 523 bytes
    - Click Count (0)
  8. docs_src/response_model/tutorial001_py39.py

    from typing import Any, Union
    
    from fastapi import FastAPI
    from pydantic import BaseModel
    
    app = FastAPI()
    
    
    class Item(BaseModel):
        name: str
        description: Union[str, None] = None
        price: float
        tax: Union[float, None] = None
        tags: list[str] = []
    
    
    @app.post("/items/", response_model=Item)
    async def create_item(item: Item) -> Any:
        return item
    
    
    @app.get("/items/", response_model=list[Item])
    Created: Sun Dec 28 07:19:09 GMT 2025
    - Last Modified: Sat Jan 07 13:45:48 GMT 2023
    - 556 bytes
    - Click Count (0)
  9. tests/test_request_params/test_file/test_optional_list.py

    async def read_optional_list_bytes(p: Annotated[Optional[list[bytes]], File()] = None):
        return {"file_size": [len(file) for file in p] if p else None}
    
    
    @app.post("/optional-list-uploadfile")
    async def read_optional_list_uploadfile(
        p: Annotated[Optional[list[UploadFile]], File()] = None,
    ):
        return {"file_size": [file.size for file in p] if p else None}
    
    
    @pytest.mark.parametrize(
        "path",
        [
    Created: Sun Dec 28 07:19:09 GMT 2025
    - Last Modified: Sat Dec 27 18:19:10 GMT 2025
    - 10.4K bytes
    - Click Count (0)
  10. tests/test_params_repr.py

    from fastapi.params import Body, Cookie, Header, Param, Path, Query
    
    test_data: list[Any] = ["teststr", None, ..., 1, []]
    
    
    def get_user():
        return {}  # pragma: no cover
    
    
    def test_param_repr_str():
        assert repr(Param("teststr")) == "Param(teststr)"
    
    
    def test_param_repr_none():
        assert repr(Param(None)) == "Param(None)"
    
    
    def test_param_repr_ellipsis():
        assert repr(Param(...)) == "Param(PydanticUndefined)"
    Created: Sun Dec 28 07:19:09 GMT 2025
    - Last Modified: Sat Dec 27 18:19:10 GMT 2025
    - 2.3K bytes
    - Click Count (0)
Back to Top