- Sort Score
- Num 10 results
- Language All
Results 91 - 100 of 1,155 for noneOf (0.13 seconds)
-
docs/fr/docs/tutorial/query-params-str-validations.md
Nous avions cette annotation de type : ```Python q: str | None = None ``` Ce que nous allons faire, c’est l’englober avec `Annotated`, de sorte que cela devienne : ```Python q: Annotated[str | None] = None ``` Les deux versions signifient la même chose, `q` est un paramètre qui peut être une `str` ou `None`, et par défaut, c’est `None`. Passons maintenant aux choses amusantes. 🎉
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Thu Mar 19 18:37:13 GMT 2026 - 19K bytes - Click Count (0) -
tests/test_request_params/test_form/test_required_str.py
assert response.json() == { "detail": [ { "type": "missing", "loc": ["body", "p"], "msg": "Field required", "input": IsOneOf(None, {}), } ] } @pytest.mark.parametrize( "path", ["/required-str", "/model-required-str"], ) def test_required_str(path: str): client = TestClient(app)
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Sat Dec 27 18:19:10 GMT 2025 - 10.6K bytes - Click Count (0) -
tests/test_tutorial/test_body_multiple_params/test_tutorial001.py
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Thu Feb 12 13:19:43 GMT 2026 - 6.9K bytes - Click Count (0) -
src/main/webapp/css/admin/style.css
ul.has-error { color: #dd4b39 !important; list-style-type: none; padding: 0; } .form-group .has-error + .form-control { border-color: #dd4b39 !important; box-shadow: none; } .sidebar-mini.sidebar-collapse .sidebar-search { display: none !important; } input[type="file"].form-control:not([type="file"]) { height: 0% !important; } #result ol { list-style: none !important; padding-left: 0; }Created: Tue Mar 31 13:07:34 GMT 2026 - Last Modified: Mon Feb 23 08:03:44 GMT 2026 - 1.3K bytes - Click Count (0) -
docs/zh-hant/docs/tutorial/query-params-str-validations.md
在這種情況下(未使用 `Annotated`),我們必須用 `Query()` 取代函式中的預設值 `None`,因此需要用 `Query(default=None)` 來設定預設值;對 FastAPI 而言,這達到相同目的。 所以: ```Python q: str | None = Query(default=None) ``` …會讓參數變為可選、預設值是 `None`,等同於: ```Python q: str | None = None ``` 但用 `Query` 的版本會明確宣告它是查詢參數。 接著,我們可以傳更多參數給 `Query`。此例中是用於字串的 `max_length` 參數: ```Python q: str | None = Query(default=None, max_length=50) ```
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Fri Mar 20 17:05:38 GMT 2026 - 14.8K bytes - Click Count (0) -
src/test/java/org/codelibs/fess/helper/QueryHelperTest.java
...
Created: Tue Mar 31 13:07:34 GMT 2026 - Last Modified: Fri Mar 13 23:01:26 GMT 2026 - 53.2K bytes - Click Count (0) -
docs_src/body_multiple_params/tutorial001_py310.py
app = FastAPI() class Item(BaseModel): name: str description: str | None = None price: float tax: float | None = None @app.put("/items/{item_id}") async def update_item( *, item_id: int = Path(title="The ID of the item to get", ge=0, le=1000), q: str | None = None, item: Item | None = None, ): results = {"item_id": item_id} if q: results.update({"q": q})
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Fri May 13 23:38:22 GMT 2022 - 546 bytes - Click Count (0) -
tests/test_request_params/test_file/test_list.py
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Sat Feb 21 13:01:31 GMT 2026 - 11.6K bytes - Click Count (0) -
docs_src/sql_databases/tutorial001_an_py310.py
from sqlmodel import Field, Session, SQLModel, create_engine, select class Hero(SQLModel, table=True): id: int | None = Field(default=None, primary_key=True) name: str = Field(index=True) age: int | None = Field(default=None, index=True) secret_name: str sqlite_file_name = "database.db" sqlite_url = f"sqlite:///{sqlite_file_name}"
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Wed Oct 09 19:44:42 GMT 2024 - 1.7K bytes - Click Count (0) -
tests/test_form_default.py
app = FastAPI() @app.post("/urlencoded") async def post_url_encoded(age: Annotated[int | None, Form()] = None): return age @app.post("/multipart") async def post_multi_part( age: Annotated[int | None, Form()] = None, file: Annotated[bytes | None, File()] = None, ): return {"file": file, "age": age} client = TestClient(app) def test_form_default_url_encoded():
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Tue Feb 17 09:59:14 GMT 2026 - 829 bytes - Click Count (0)