- Sort Score
- Num 10 results
- Language All
Results 831 - 840 of 1,096 for sltr (0.02 seconds)
-
tests/test_dependency_contextvars.py
from contextvars import ContextVar from typing import Any from fastapi import Depends, FastAPI, Request, Response from fastapi.testclient import TestClient legacy_request_state_context_var: ContextVar[dict[str, Any] | None] = ContextVar( "legacy_request_state_context_var", default=None ) app = FastAPI() async def set_up_request_state_dependency(): request_state = {"user": "deadpond"}
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Tue Feb 17 09:59:14 GMT 2026 - 1.5K bytes - Click Count (0) -
docs/en/docs/tutorial/query-params.md
{* ../../docs_src/query_params/tutorial005_py310.py hl[6:7] *} Here the query parameter `needy` is a required query parameter of type `str`. If you open in your browser a URL like: ``` http://127.0.0.1:8000/items/foo-item ``` ...without adding the required parameter `needy`, you will see an error like: ```JSON {Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Thu Mar 05 18:13:19 GMT 2026 - 4.5K bytes - Click Count (0) -
docs/zh/docs/tutorial/body-updates.md
## 用 `PUT` 替换式更新 { #update-replacing-with-put } 更新数据可以使用 [HTTP `PUT`](https://developer.mozilla.org/en-US/docs/Web/HTTP/Methods/PUT) 操作。 把输入数据转换为以 JSON 格式存储的数据(比如,使用 NoSQL 数据库时),可以使用 `jsonable_encoder`。例如,把 `datetime` 转换为 `str`。 {* ../../docs_src/body_updates/tutorial001_py310.py hl[28:33] *} `PUT` 用于接收替换现有数据的数据。 ### 关于替换的警告 { #warning-about-replacing } 用 `PUT` 把数据项 `bar` 更新为以下请求体时: ```Python { "name": "Barz",Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Fri Mar 20 17:06:37 GMT 2026 - 3.7K bytes - Click Count (0) -
cmd/update_test.go
} } str := getUserAgent(testCase.mode) expectedStr := testCase.expectedStr if IsDocker() { expectedStr = strings.ReplaceAll(expectedStr, "; source", "; docker; source") } if !strings.Contains(str, expectedStr) { t.Errorf("Test %d: expected: %s, got: %s", i+1, expectedStr, str) } os.Unsetenv("MARATHON_APP_LABEL_DCOS_PACKAGE_VERSION")
Created: Sun Apr 05 19:28:12 GMT 2026 - Last Modified: Tue Feb 18 16:25:55 GMT 2025 - 10.4K bytes - Click Count (0) -
docs/ko/docs/tutorial/response-model.md
응답 모델은 아래와 같이 기본값을 가질 수 있습니다: {* ../../docs_src/response_model/tutorial004_py310.py hl[9,11:12] *} * `description: Union[str, None] = None` (또는 Python 3.10에서 `str | None = None`)은 기본값으로 `None`을 갖습니다. * `tax: float = 10.5`는 기본값으로 `10.5`를 갖습니다. * `tags: List[str] = []`는 기본값으로 빈 리스트 `[]`를 갖습니다. 하지만 실제로 저장되지 않았을 경우 결과에서 이를 생략하고 싶을 수 있습니다.Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Fri Mar 20 14:06:26 GMT 2026 - 17.9K bytes - Click Count (0) -
compat/maven-embedder/src/test/java/org/apache/maven/cli/props/MavenPropertiesTest.java
@Test public void testSubstitution() throws IOException { String str = "port = 4141" + LINE_SEPARATOR + "host = localhost" + LINE_SEPARATOR + "url = https://${host}:${port}/service" + LINE_SEPARATOR; MavenProperties properties = new MavenProperties(); properties.load(new StringReader(str)); properties.put("url", "https://localhost:4141/service");Created: Sun Apr 05 03:35:12 GMT 2026 - Last Modified: Mon Mar 09 14:29:03 GMT 2026 - 16.3K bytes - Click Count (0) -
docs/es/docs/advanced/custom-response.md
Puedes devolverla directamente. Acepta los siguientes parámetros: * `content` - Un `str` o `bytes`. * `status_code` - Un código de estado HTTP `int`. * `headers` - Un `dict` de strings. * `media_type` - Un `str` que da el media type. Por ejemplo, `"text/html"`.
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Thu Mar 19 18:15:55 GMT 2026 - 11.6K bytes - Click Count (0) -
docs/en/docs/advanced/settings.md
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Thu Mar 05 18:13:19 GMT 2026 - 10.9K bytes - Click Count (0) -
src/cmd/asm/internal/asm/endtoend_test.go
if len(f) > 0 && strings.Contains(printed, "(PC)") { index := len(f) - 1 suf := "(PC)" for !strings.HasSuffix(f[index], suf) { index-- suf = "(PC)," } str := f[index] n, err := strconv.Atoi(str[:len(str)-len(suf)]) if err == nil { f[index] = fmt.Sprintf("%d%s", seq+n, suf) } } if len(f) == 1 { printed = f[0] } else {
Created: Tue Apr 07 11:13:11 GMT 2026 - Last Modified: Fri Mar 20 17:02:17 GMT 2026 - 12.6K bytes - Click Count (0) -
docs/de/docs/tutorial/dependencies/classes-as-dependencies.md
Möglicherweise stellen Sie fest, dass Sie zum Erstellen einer Instanz einer Python-Klasse die gleiche Syntax verwenden. Zum Beispiel: ```Python class Cat: def __init__(self, name: str): self.name = name fluffy = Cat(name="Mr Fluffy") ``` In diesem Fall ist `fluffy` eine Instanz der Klasse `Cat`. Und um `fluffy` zu erzeugen, rufen Sie `Cat` auf.Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Sat Feb 14 07:57:30 GMT 2026 - 7.6K bytes - Click Count (0)