Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 5 of 5 for extends (0.18 sec)

  1. fastapi/dependencies/utils.py

            )
            flat_dependant.path_params.extend(flat_sub.path_params)
            flat_dependant.query_params.extend(flat_sub.query_params)
            flat_dependant.header_params.extend(flat_sub.header_params)
            flat_dependant.cookie_params.extend(flat_sub.cookie_params)
            flat_dependant.body_params.extend(flat_sub.body_params)
            flat_dependant.security_requirements.extend(flat_sub.security_requirements)
        return flat_dependant
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Tue Apr 02 02:52:56 GMT 2024
    - 29.5K bytes
    - Viewed (0)
  2. fastapi/openapi/utils.py

                if route.response_fields:
                    responses_from_routes.extend(route.response_fields.values())
                if route.callbacks:
                    callback_flat_models.extend(get_fields_from_routes(route.callbacks))
                params = get_flat_params(route.dependant)
                request_fields_from_routes.extend(params)
    
        flat_models = callback_flat_models + list(
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 21.8K bytes
    - Viewed (0)
  3. fastapi/routing.py

                        current_tags.extend(tags)
                    if route.tags:
                        current_tags.extend(route.tags)
                    current_dependencies: List[params.Depends] = []
                    if dependencies:
                        current_dependencies.extend(dependencies)
                    if route.dependencies:
                        current_dependencies.extend(route.dependencies)
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Tue Apr 02 02:48:51 GMT 2024
    - 170.1K bytes
    - Viewed (0)
  4. fastapi/_compat.py

                        errors=[error], model=RequestErrorModel
                    ).errors()
                    use_errors.extend(new_errors)
                elif isinstance(error, list):
                    use_errors.extend(_normalize_errors(error))
                else:
                    use_errors.append(error)
            return use_errors
    
        def _model_rebuild(model: Type[BaseModel]) -> None:
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 22.6K bytes
    - Viewed (0)
  5. tests/test_union_inherited_body.py

    class ExtendedItem(Item):
        age: int
    
    
    @app.post("/items/")
    def save_union_different_body(item: Union[ExtendedItem, Item]):
        return {"item": item}
    
    
    client = TestClient(app)
    
    
    def test_post_extended_item():
        response = client.post("/items/", json={"name": "Foo", "age": 5})
        assert response.status_code == 200, response.text
        assert response.json() == {"item": {"name": "Foo", "age": 5}}
    
    
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Fri Jul 07 17:12:13 GMT 2023
    - 5.2K bytes
    - Viewed (0)
Back to top