Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 75 for what (0.19 sec)

  1. fastapi/security/oauth2.py

            return data
        ```
    
        Note that for OAuth2 the scope `items:read` is a single scope in an opaque string.
        You could have custom internal logic to separate it by colon caracters (`:`) or
        similar, and get the two parts `items` and `read`. Many applications do that to
        group and organize permissions, you could do it as well in your application, just
        know that that it is application specific, it's not part of the specification.
    Python
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Tue Apr 02 02:48:51 GMT 2024
    - 21.1K bytes
    - Viewed (1)
  2. tests/test_compat.py

    
    @needs_pydanticv1
    def test_union_scalar_list():
        # For coverage
        # TODO: there might not be a current valid code path that uses this, it would
        # potentially enable query parameters defined as both a scalar and a list
        # but that would require more refactors, also not sure it's really useful
        from fastapi._compat import is_pv1_scalar_field
    
        field_info = FieldInfo()
        field = ModelField(
    Python
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Thu Sep 28 04:14:40 GMT 2023
    - 2.8K bytes
    - Viewed (0)
  3. docs_src/websockets/tutorial003.py

    from fastapi import FastAPI, WebSocket, WebSocketDisconnect
    from fastapi.responses import HTMLResponse
    
    app = FastAPI()
    
    html = """
    <!DOCTYPE html>
    <html>
        <head>
            <title>Chat</title>
        </head>
        <body>
            <h1>WebSocket Chat</h1>
            <h2>Your ID: <span id="ws-id"></span></h2>
            <form action="" onsubmit="sendMessage(event)">
                <input type="text" id="messageText" autocomplete="off"/>
    Python
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Sun Aug 09 13:52:19 GMT 2020
    - 2.5K bytes
    - Viewed (0)
  4. ci/official/containers/linux_arm64/devel.usertools/squash_testlogs.py

    Example: squash_testlogs.py /tf/pkg/testlogs /tf/pkg/merged.xml
    
    Recursively find all the JUnit test.xml files in one directory, and merge any
    of them that contain failures into one file. The TensorFlow DevInfra team
    uses this to generate a simple overview of an entire pip and nonpip test
    invocation, since the normal logs that Bazel creates are too large for the
    internal invocation viewer.
    """
    import collections
    import os
    import re
    import subprocess
    Python
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Mon Sep 18 19:00:37 GMT 2023
    - 4.8K bytes
    - Viewed (0)
  5. fastapi/param_functions.py

                OpenAPI-specific examples.
    
                It will be added to the generated OpenAPI (e.g. visible at `/docs`).
    
                Swagger UI (that provides the `/docs` interface) has better support for the
                OpenAPI-specific examples than the JSON Schema `examples`, that's the main
                use case for this.
    
                Read more about it in the
    Python
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 62.5K bytes
    - Viewed (0)
  6. fastapi/security/http.py

            return HTTPAuthorizationCredentials(scheme=scheme, credentials=credentials)
    
    
    class HTTPBasic(HTTPBase):
        """
        HTTP Basic authentication.
    
        ## Usage
    
        Create an instance object and use that object as the dependency in `Depends()`.
    
        The dependency result will be an `HTTPBasicCredentials` object containing the
        `username` and the `password`.
    
        Read more about it in the
    Python
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Fri Apr 19 15:29:38 GMT 2024
    - 13.2K bytes
    - Viewed (0)
  7. tests/test_tutorial/test_query_params_str_validations/test_tutorial010_an.py

                        "operationId": "read_items_items__get",
                        "parameters": [
                            {
                                "description": "Query string for the items to search in the database that have a good match",
                                "required": False,
                                "deprecated": True,
                                "schema": IsDict(
                                    {
    Python
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 6.2K bytes
    - Viewed (0)
  8. docs_src/websockets/tutorial002_an_py310.py

        WebSocketException,
        status,
    )
    from fastapi.responses import HTMLResponse
    
    app = FastAPI()
    
    html = """
    <!DOCTYPE html>
    <html>
        <head>
            <title>Chat</title>
        </head>
        <body>
            <h1>WebSocket Chat</h1>
            <form action="" onsubmit="sendMessage(event)">
                <label>Item ID: <input type="text" id="itemId" autocomplete="off" value="foo"/></label>
    Python
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Sat Mar 18 12:29:59 GMT 2023
    - 2.8K bytes
    - Viewed (0)
  9. fastapi/params.py

            decimal_places: Union[int, None] = _Unset,
            examples: Optional[List[Any]] = None,
            example: Annotated[
                Optional[Any],
                deprecated(
                    "Deprecated in OpenAPI 3.1.0 that now uses JSON Schema 2020-12, "
                    "although still supported. Use examples instead."
                ),
            ] = _Unset,
            openapi_examples: Optional[Dict[str, Example]] = None,
    Python
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 27.5K bytes
    - Viewed (1)
  10. docs_src/query_params_str_validations/tutorial010.py

    @app.get("/items/")
    async def read_items(
        q: Union[str, None] = Query(
            default=None,
            alias="item-query",
            title="Query string",
            description="Query string for the items to search in the database that have a good match",
            min_length=3,
            max_length=50,
            pattern="^fixedquery$",
            deprecated=True,
        ),
    ):
        results = {"items": [{"item_id": "Foo"}, {"item_id": "Bar"}]}
        if q:
    Python
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Tue Oct 24 20:26:06 GMT 2023
    - 574 bytes
    - Viewed (0)
Back to top