Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 270 for Value (0.14 sec)

  1. tests/test_dependency_class.py

    
    class MethodsDependency:
        def synchronous(self, value: str) -> str:
            return value
    
        async def asynchronous(self, value: str) -> str:
            return value
    
        def synchronous_gen(self, value: str) -> Generator[str, None, None]:
            yield value
    
        async def asynchronous_gen(self, value: str) -> AsyncGenerator[str, None]:
            yield value
    
    
    callable_dependency = CallableDependency()
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sun Aug 09 10:54:05 GMT 2020
    - 3.3K bytes
    - Viewed (0)
  2. fastapi/param_functions.py

            Doc(
                """
                Default value if the parameter field is not set.
                """
            ),
        ] = Undefined,
        *,
        default_factory: Annotated[
            Union[Callable[[], Any], None],
            Doc(
                """
                A callable to generate the default value.
    
                This doesn't affect `Path` parameters as the value is always required.
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 62.5K bytes
    - Viewed (0)
  3. docs_src/websockets/tutorial002_an_py310.py

        <body>
            <h1>WebSocket Chat</h1>
            <form action="" onsubmit="sendMessage(event)">
                <label>Item ID: <input type="text" id="itemId" autocomplete="off" value="foo"/></label>
                <label>Token: <input type="text" id="token" autocomplete="off" value="some-key-token"/></label>
                <button onclick="connect(event)">Connect</button>
                <hr>
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sat Mar 18 12:29:59 GMT 2023
    - 2.8K bytes
    - Viewed (0)
  4. tests/test_tutorial/test_websockets/test_tutorial002_py310.py

                assert data == "Session cookie or query token value is: fakesession"
                data = websocket.receive_text()
                assert data == f"Message text was: {message}, for item ID: foo"
                message = "Message two"
                websocket.send_text(message)
                data = websocket.receive_text()
                assert data == "Session cookie or query token value is: fakesession"
                data = websocket.receive_text()
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sat Mar 18 12:29:59 GMT 2023
    - 3.9K bytes
    - Viewed (0)
  5. tests/test_query.py

            {
                "detail": [
                    {
                        "loc": ["query", "query"],
                        "msg": "field required",
                        "type": "value_error.missing",
                    }
                ]
            }
        )
    
    
    def test_query_query_baz():
        response = client.get("/query?query=baz")
        assert response.status_code == 200
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 21:56:59 GMT 2024
    - 11.4K bytes
    - Viewed (0)
  6. docs/de/docs/tutorial/dependencies/sub-dependencies.md

        async def needy_dependency(fresh_value: Annotated[str, Depends(get_value, use_cache=False)]):
            return {"fresh_value": fresh_value}
        ```
    
    === "Python 3.8+ nicht annotiert"
    
        !!! tip "Tipp"
            Bevorzugen Sie die `Annotated`-Version, falls möglich.
    
        ```Python hl_lines="1"
        async def needy_dependency(fresh_value: str = Depends(get_value, use_cache=False)):
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sat Mar 30 18:09:48 GMT 2024
    - 6.3K bytes
    - Viewed (0)
  7. tests/test_tutorial/test_additional_responses/test_tutorial003.py

                "schemas": {
                    "Item": {
                        "title": "Item",
                        "required": ["id", "value"],
                        "type": "object",
                        "properties": {
                            "id": {"title": "Id", "type": "string"},
                            "value": {"title": "Value", "type": "string"},
                        },
                    },
                    "Message": {
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Fri Jun 30 18:25:16 GMT 2023
    - 4.5K bytes
    - Viewed (0)
  8. docs/en/docs/tutorial/path-params.md

    ### Working with Python *enumerations*
    
    The value of the *path parameter* will be an *enumeration member*.
    
    #### Compare *enumeration members*
    
    You can compare it with the *enumeration member* in your created enum `ModelName`:
    
    ```Python hl_lines="17"
    {!../../../docs_src/path_params/tutorial005.py!}
    ```
    
    #### Get the *enumeration value*
    
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Fri Mar 22 01:42:11 GMT 2024
    - 9.1K bytes
    - Viewed (0)
  9. docs/fr/docs/advanced/additional-responses.md

    ```Python
    old_dict = {
        "old key": "old value",
        "second old key": "second old value",
    }
    new_dict = {**old_dict, "new key": "new value"}
    ```
    
    Ici, `new_dict` contiendra toutes les paires clé-valeur de `old_dict` plus la nouvelle paire clé-valeur :
    
    ```Python
    {
        "old key": "old value",
        "second old key": "second old value",
        "new key": "new value",
    }
    ```
    
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:53:19 GMT 2024
    - 9.6K bytes
    - Viewed (0)
  10. tests/test_tutorial/test_request_forms/test_tutorial001_an.py

                        "loc": ["body", "username"],
                        "msg": "field required",
                        "type": "value_error.missing",
                    },
                    {
                        "loc": ["body", "password"],
                        "msg": "field required",
                        "type": "value_error.missing",
                    },
                ]
            }
        )
    
    
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 7.5K bytes
    - Viewed (0)
Back to top