Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 17 for shallow (0.21 sec)

  1. .github/actions/people/app/main.py

        github_sponsors_old_content = github_sponsors_path.read_text(encoding="utf-8")
        new_people_content = yaml.dump(
            people, sort_keys=False, width=200, allow_unicode=True
        )
        new_github_sponsors_content = yaml.dump(
            github_sponsors, sort_keys=False, width=200, allow_unicode=True
        )
        if (
            people_old_content == new_people_content
            and github_sponsors_old_content == new_github_sponsors_content
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Tue Mar 26 17:38:21 GMT 2024
    - 19.2K bytes
    - Viewed (1)
  2. scripts/docs.py

        return config
    
    
    def update_config() -> None:
        config = get_updated_config_content()
        en_config_path.write_text(
            yaml.dump(config, sort_keys=False, width=200, allow_unicode=True),
            encoding="utf-8",
        )
    
    
    @app.command()
    def verify_config() -> None:
        """
        Verify main mkdocs.yml content to make sure it uses the latest language names.
        """
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Mon Jan 22 19:26:14 GMT 2024
    - 10.9K bytes
    - Viewed (1)
  3. fastapi/params.py

                lt=lt,
                le=le,
                min_length=min_length,
                max_length=max_length,
                discriminator=discriminator,
                multiple_of=multiple_of,
                allow_nan=allow_inf_nan,
                max_digits=max_digits,
                decimal_places=decimal_places,
                **extra,
            )
            if examples is not None:
                kwargs["examples"] = examples
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 27.5K bytes
    - Viewed (1)
  4. fastapi/param_functions.py

                """
            ),
        ] = _Unset,
        allow_inf_nan: Annotated[
            Union[bool, None],
            Doc(
                """
                Allow `inf`, `-inf`, `nan`. Only applicable to numbers.
                """
            ),
        ] = _Unset,
        max_digits: Annotated[
            Union[int, None],
            Doc(
                """
                Maximum number of allow digits for strings.
                """
            ),
    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)
  5. tests/test_compat.py

        # TODO: in theory this would allow declaring types that could be lists of bytes
        # to be read from files and other types, but I'm not even sure it's a good idea
        # to support it as a first class "feature"
        assert is_bytes_sequence_annotation(Union[List[str], List[bytes]])
    
    
    def test_is_uploadfile_sequence_annotation():
        # For coverage
        # TODO: in theory this would allow declaring types that could be lists of UploadFile
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Sep 28 04:14:40 GMT 2023
    - 2.8K bytes
    - Viewed (0)
  6. fastapi/utils.py

        new_field.required = field.required  # type: ignore[misc]
        new_field.model_config = field.model_config  # type: ignore[attr-defined]
        new_field.field_info = field.field_info
        new_field.allow_none = field.allow_none  # type: ignore[attr-defined]
        new_field.validate_always = field.validate_always  # type: ignore[attr-defined]
        if field.sub_fields:  # type: ignore[attr-defined]
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 7.8K bytes
    - Viewed (0)
  7. docs_src/dependencies/tutorial008d.py

    app = FastAPI()
    
    
    class InternalError(Exception):
        pass
    
    
    def get_username():
        try:
            yield "Rick"
        except InternalError:
            print("We don't swallow the internal error here, we raise again 😎")
            raise
    
    
    @app.get("/items/{item_id}")
    def get_item(item_id: str, username: str = Depends(get_username)):
        if item_id == "portal-gun":
            raise InternalError(
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sat Feb 24 23:06:37 GMT 2024
    - 694 bytes
    - Viewed (0)
  8. docs_src/dependencies/tutorial008d_an.py

    from typing_extensions import Annotated
    
    app = FastAPI()
    
    
    class InternalError(Exception):
        pass
    
    
    def get_username():
        try:
            yield "Rick"
        except InternalError:
            print("We don't swallow the internal error here, we raise again 😎")
            raise
    
    
    @app.get("/items/{item_id}")
    def get_item(item_id: str, username: Annotated[str, Depends(get_username)]):
        if item_id == "portal-gun":
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sat Feb 24 23:06:37 GMT 2024
    - 744 bytes
    - Viewed (0)
  9. docs_src/dependencies/tutorial008d_an_py39.py

    app = FastAPI()
    
    
    class InternalError(Exception):
        pass
    
    
    def get_username():
        try:
            yield "Rick"
        except InternalError:
            print("We don't swallow the internal error here, we raise again 😎")
            raise
    
    
    @app.get("/items/{item_id}")
    def get_item(item_id: str, username: Annotated[str, Depends(get_username)]):
        if item_id == "portal-gun":
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sat Feb 24 23:06:37 GMT 2024
    - 734 bytes
    - Viewed (0)
  10. docs/sts/web-identity.py

        data = {'grant_type': 'authorization_code',
                'code': authorization_code, 'redirect_uri': callback_uri}
        id_token_response = requests.post(
            token_url, data=data, verify=False,
            allow_redirects=False, auth=(client_id, client_secret))
    
        print('body: ' + id_token_response.text)
    
        # we can now use the id_token as much as we want to access protected resources.
    Python
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Wed Jul 28 01:37:51 GMT 2021
    - 2.9K bytes
    - Viewed (1)
Back to top