Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 28 for amatch (0.26 sec)

  1. tests/test_tutorial/test_query_params_str_validations/test_tutorial010_an.py

            {
                "detail": [
                    {
                        "type": "string_pattern_mismatch",
                        "loc": ["query", "item-query"],
                        "msg": "String should match pattern '^fixedquery$'",
                        "input": "nonregexquery",
                        "ctx": {"pattern": "^fixedquery$"},
                    }
                ]
            }
        ) | IsDict(
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 6.2K bytes
    - Viewed (0)
  2. docs_src/query_params_str_validations/tutorial010.py

    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 28 07:19:10 GMT 2024
    - Last Modified: Tue Oct 24 20:26:06 GMT 2023
    - 574 bytes
    - Viewed (0)
  3. ci/official/utilities/extract_resultstore_links.py

      result_store_links: ResultDictType = {}
      current_url = None
      for i in range(len(log_lines)):
        line = log_lines[i]
        result_store_line_match = re.search(RESULT_STORE_LINK_RE, line)
        if not result_store_line_match:
          continue
    
        url = result_store_line_match.group(1)
        url_lines = result_store_links.setdefault(url, {})
        # Each bazel RBE invocation should produce two
    Python
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Wed Nov 08 17:50:27 GMT 2023
    - 10.9K bytes
    - Viewed (0)
  4. docs_src/query_params_str_validations/tutorial008.py

    
    @app.get("/items/")
    async def read_items(
        q: Union[str, None] = Query(
            default=None,
            title="Query string",
            description="Query string for the items to search in the database that have a good match",
            min_length=3,
        ),
    ):
        results = {"items": [{"item_id": "Foo"}, {"item_id": "Bar"}]}
        if q:
            results.update({"q": q})
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Tue Oct 24 20:26:06 GMT 2023
    - 466 bytes
    - Viewed (0)
  5. docs_src/query_params_str_validations/tutorial010_an.py

        q: Annotated[
            Union[str, None],
            Query(
                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,
            ),
        ] = None,
    ):
        results = {"items": [{"item_id": "Foo"}, {"item_id": "Bar"}]}
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Tue Oct 24 20:26:06 GMT 2023
    - 664 bytes
    - Viewed (0)
  6. tests/test_security_oauth2_optional.py

            {
                "detail": [
                    {
                        "type": "string_pattern_mismatch",
                        "loc": ["body", "grant_type"],
                        "msg": "String should match pattern 'password'",
                        "input": "incorrect",
                        "ctx": {"pattern": "password"},
                    }
                ]
            }
        ) | IsDict(
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 10.8K bytes
    - Viewed (0)
  7. tests/test_ws_router.py

        # and no error is leaked
        assert caught == []
    
    
    def test_depend_err_middleware():
        """
        Verify that it is possible to write custom WebSocket middleware to catch errors
        """
    
        @websocket_middleware
        async def errorhandler(websocket: WebSocket, call_next):
            try:
                return await call_next()
            except Exception as e:
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sun Jun 11 19:08:14 GMT 2023
    - 7.5K bytes
    - Viewed (0)
  8. tests/test_multipart_installation.py

        with pytest.raises(RuntimeError, match=multipart_incorrect_install_error):
            app = FastAPI()
    
            @app.post("/")
            async def root(f: bytes = File()):
                return f  # pragma: nocover
    
    
    def test_incorrect_multipart_installed_multi_form(monkeypatch):
        monkeypatch.delattr("multipart.multipart.parse_options_header", raising=False)
        with pytest.raises(RuntimeError, match=multipart_incorrect_install_error):
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Fri May 13 23:38:22 GMT 2022
    - 3.7K bytes
    - Viewed (0)
  9. tests/test_ambiguous_params.py

    def test_no_annotated_defaults():
        with pytest.raises(
            AssertionError, match="Path parameters cannot have a default value"
        ):
    
            @app.get("/items/{item_id}/")
            async def get_item(item_id: Annotated[int, Path(default=1)]):
                pass  # pragma: nocover
    
        with pytest.raises(
            AssertionError,
            match=(
                "`Query` default value cannot be set in `Annotated` for 'item_id'. Set the"
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Tue Dec 12 00:22:47 GMT 2023
    - 2.1K bytes
    - Viewed (0)
  10. tests/test_tutorial/test_query_params_str_validations/test_tutorial010_an_py39.py

            {
                "detail": [
                    {
                        "type": "string_pattern_mismatch",
                        "loc": ["query", "item-query"],
                        "msg": "String should match pattern '^fixedquery$'",
                        "input": "nonregexquery",
                        "ctx": {"pattern": "^fixedquery$"},
                    }
                ]
            }
        ) | IsDict(
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 6.3K bytes
    - Viewed (0)
Back to top