Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 19 for and (0.25 sec)

  1. .github/actions/notify-translations/app/main.py

        # Avoid race conditions with multiple labels
        sleep_time = random.random() * 10  # random number between 0 and 10 seconds
        logging.info(
            f"Sleeping for {sleep_time} seconds to avoid "
            "race conditions and multiple comments"
        )
        time.sleep(sleep_time)
    
        # Get PR
        logging.debug(f"Processing PR: #{github_event.pull_request.number}")
    Python
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Wed Sep 27 23:01:46 GMT 2023
    - 12.4K bytes
    - Viewed (0)
  2. tests/test_tutorial/test_request_forms_and_files/test_tutorial001_an.py

    import pytest
    from dirty_equals import IsDict
    from fastapi import FastAPI
    from fastapi.testclient import TestClient
    
    
    @pytest.fixture(name="app")
    def get_app():
        from docs_src.request_forms_and_files.tutorial001_an import app
    
        return app
    
    
    @pytest.fixture(name="client")
    def get_client(app: FastAPI):
        client = TestClient(app)
        return client
    
    
    def test_post_form_no_body(client: TestClient):
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 9.8K bytes
    - Viewed (0)
  3. .github/actions/people/app/main.py

                            translation_reviewers[review.author.login] += 1
                            break
            for reviewer in pr_reviewers:
                reviewers[reviewer] += 1
            if pr.state == "MERGED" and pr.author:
                contributors[pr.author.login] += 1
        return ContributorsResults(
            contributors=contributors,
            commenters=commenters,
            reviewers=reviewers,
    Python
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Tue Mar 26 17:38:21 GMT 2024
    - 19.2K bytes
    - Viewed (1)
  4. tests/test_schema_extra_examples.py

        """
        Test that example overrides work:
    
        * pydantic model schema_extra is included
        * Body(example={}) overrides schema_extra in pydantic model
        * Body(examples{}) overrides Body(example={}) and schema_extra in pydantic model
        """
        app = create_app()
        client = TestClient(app)
        response = client.get("/openapi.json")
        assert response.status_code == 200, response.text
    Python
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Tue Oct 24 20:26:06 GMT 2023
    - 37.7K bytes
    - Viewed (0)
  5. fastapi/security/oauth2.py

        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.
    
    
        grant_type: the OAuth2 spec says it is required and MUST be the fixed string "password".
    Python
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Tue Apr 02 02:48:51 GMT 2024
    - 21.1K bytes
    - Viewed (1)
  6. fastapi/security/http.py

        ) -> Optional[HTTPAuthorizationCredentials]:
            authorization = request.headers.get("Authorization")
            scheme, credentials = get_authorization_scheme_param(authorization)
            if not (authorization and scheme and credentials):
                if self.auto_error:
                    raise HTTPException(
                        status_code=HTTP_403_FORBIDDEN, detail="Not authenticated"
                    )
                else:
    Python
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Fri Apr 19 15:29:38 GMT 2024
    - 13.2K bytes
    - Viewed (0)
  7. ci/official/utilities/extract_resultstore_links.py

    # See the License for the specific language governing permissions and
    # limitations under the License.
    # ==============================================================================
    
    """Extracts ResultStore links from a log containing Bazel invocations.
    
    The links and the invocations' status can then be printed out, or output in the
    form of JUnit-based XML.
    """
    import argparse
    Python
    - Registered: Tue Apr 30 12:39:09 GMT 2024
    - Last Modified: Wed Nov 08 17:50:27 GMT 2023
    - 10.9K bytes
    - Viewed (0)
  8. fastapi/params.py

            max_length: Optional[int] = None,
            pattern: Optional[str] = None,
            regex: Annotated[
                Optional[str],
                deprecated(
                    "Deprecated in FastAPI 0.100.0 and Pydantic v2, use `pattern` instead."
                ),
            ] = None,
            discriminator: Union[str, None] = None,
            strict: Union[bool, None] = _Unset,
            multiple_of: Union[float, None] = _Unset,
    Python
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 27.5K bytes
    - Viewed (1)
  9. tests/test_tutorial/test_request_forms_and_files/test_tutorial001.py

    import pytest
    from dirty_equals import IsDict
    from fastapi import FastAPI
    from fastapi.testclient import TestClient
    
    
    @pytest.fixture(name="app")
    def get_app():
        from docs_src.request_forms_and_files.tutorial001 import app
    
        return app
    
    
    @pytest.fixture(name="client")
    def get_client(app: FastAPI):
        client = TestClient(app)
        return client
    
    
    def test_post_form_no_body(client: TestClient):
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 9.8K bytes
    - Viewed (0)
  10. fastapi/dependencies/utils.py

                if (
                    isinstance(field_info, params.File)
                    and is_bytes_field(field)
                    and isinstance(value, UploadFile)
                ):
                    value = await value.read()
                elif (
                    is_bytes_sequence_field(field)
                    and isinstance(field_info, params.File)
                    and value_is_sequence(value)
                ):
                    # For types
    Python
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Tue Apr 02 02:52:56 GMT 2024
    - 29.5K bytes
    - Viewed (0)
Back to top