Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 8 of 8 for rapides (0.04 sec)

  1. tests/test_pydantic_v1_error.py

        app = FastAPI()
    
        with pytest.raises(PydanticV1NotSupportedError):
    
            @app.post("/param")
            def endpoint(data: ParamModelV1):  # pragma: no cover
                return data
    
    
    def test_raises_pydantic_v1_model_in_return_type() -> None:
        class ReturnModelV1(BaseModel):
            name: str
    
        app = FastAPI()
    
        with pytest.raises(PydanticV1NotSupportedError):
    
            @app.get("/return")
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Sat Dec 27 12:54:56 UTC 2025
    - 2.3K bytes
    - Viewed (0)
  2. tests/test_jsonable_encoder.py

            name: str
    
        data = ModelV1(name="test")
        with pytest.raises(PydanticV1NotSupportedError):
            jsonable_encoder(data)
    
    
    def test_encode_model_with_config():
        model = ModelWithConfig(role=RoleEnum.admin)
        assert jsonable_encoder(model) == {"role": "admin"}
    
    
    def test_encode_model_with_alias_raises():
        with pytest.raises(ValidationError):
            ModelWithAlias(foo="Bar")
    
    
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Sat Dec 27 12:54:56 UTC 2025
    - 9.2K bytes
    - Viewed (0)
  3. tests/test_response_model_as_return_annotation.py

    
    def test_response_model_no_annotation_return_invalid_dict():
        with pytest.raises(ResponseValidationError) as excinfo:
            client.get("/response_model-no_annotation-return_invalid_dict")
        assert "missing" in str(excinfo.value)
    
    
    def test_response_model_no_annotation_return_invalid_model():
        with pytest.raises(ResponseValidationError) as excinfo:
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Sat Dec 27 12:54:56 UTC 2025
    - 47.7K bytes
    - Viewed (0)
  4. tests/test_inherited_custom_class.py

        def return_fast_uuid():
            asyncpg_uuid = MyUuid("a10ff360-3b1e-4984-a26f-d3ab460bdb51")
            assert isinstance(asyncpg_uuid, uuid.UUID)
            assert type(asyncpg_uuid) is not uuid.UUID
            with pytest.raises(TypeError):
                vars(asyncpg_uuid)
            return {"fast_uuid": asyncpg_uuid}
    
        class SomeCustomClass(BaseModel):
            model_config = {"arbitrary_types_allowed": True}
    
            a_uuid: MyUuid
    
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Sat Dec 27 12:54:56 UTC 2025
    - 1.8K bytes
    - Viewed (0)
  5. tests/test_filter_pydantic_sub_model_pv2.py

            "description": "model-a-desc",
            "foo": {"username": "test-user"},
            "tags": {"key1": "value1", "key2": "value2"},
        }
    
    
    def test_validator_is_cloned(client: TestClient):
        with pytest.raises(ResponseValidationError) as err:
            client.get("/model/modelX")
        assert err.value.errors() == [
            {
                "type": "value_error",
                "loc": ("response", "name"),
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Sat Dec 27 18:19:10 UTC 2025
    - 6.6K bytes
    - Viewed (0)
  6. pyproject.toml

        'ignore:datetime\.datetime\.utcfromtimestamp\(\) is deprecated and scheduled for removal in a future version\..*:DeprecationWarning:sqlalchemy',
        # Trio 24.1.0 raises a warning from attrs
        # Ref: https://github.com/python-trio/trio/pull/3054
        # Remove once there's a new version of Trio
        'ignore:The `hash` argument is deprecated*:DeprecationWarning:trio',
    ]
    
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Sat Dec 27 12:54:56 UTC 2025
    - 9.3K bytes
    - Viewed (0)
  7. fastapi/routing.py

                    ],
                    body=e.doc,
                    endpoint_ctx=endpoint_ctx,
                )
                raise validation_error from e
            except HTTPException:
                # If a middleware raises an HTTPException, it should be raised again
                raise
            except Exception as e:
                http_error = HTTPException(
                    status_code=400, detail="There was an error parsing the body"
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Sat Dec 27 12:54:56 UTC 2025
    - 174.6K bytes
    - Viewed (0)
  8. docs/en/docs/release-notes.md

    ## 0.115.9
    
    ### Fixes
    
    * 🐛 Ensure that `HTTPDigest` only raises an exception when `auto_error is True`. PR [#2939](https://github.com/fastapi/fastapi/pull/2939) by [@arthurio](https://github.com/arthurio).
    
    ### Refactors
    
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Sat Dec 27 19:06:15 UTC 2025
    - 586.7K bytes
    - Viewed (0)
Back to top