- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 10 for useCache (0.11 sec)
-
tests/test_params_repr.py
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jul 07 17:12:13 UTC 2023 - 3.3K bytes - Viewed (0) -
docs/en/docs/tutorial/dependencies/sub-dependencies.md
//// tab | Python 3.8+ ```Python hl_lines="1" async def needy_dependency(fresh_value: Annotated[str, Depends(get_value, use_cache=False)]): return {"fresh_value": fresh_value} ``` //// //// tab | Python 3.8+ non-Annotated /// tip
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 06 20:36:54 UTC 2024 - 5.5K bytes - Viewed (0) -
docs/ru/docs/tutorial/dependencies/sub-dependencies.md
//// tab | Python 3.6+ ```Python hl_lines="1" async def needy_dependency(fresh_value: Annotated[str, Depends(get_value, use_cache=False)]): return {"fresh_value": fresh_value} ``` //// //// tab | Python 3.6+ без Annotated
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 06 20:36:54 UTC 2024 - 8.7K bytes - Viewed (0) -
docs/pt/docs/tutorial/dependencies/sub-dependencies.md
//// tab | Python 3.8+ ```Python hl_lines="1" async def needy_dependency(fresh_value: Annotated[str, Depends(get_value, use_cache=False)]): return {"fresh_value": fresh_value} ``` //// //// tab | Python 3.8+ non-Annotated /// tip | "Dica"
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 06 20:36:54 UTC 2024 - 5.9K bytes - Viewed (0) -
docs/em/docs/tutorial/dependencies/sub-dependencies.md
🏧 😐 🌐❔ 👆 💭 👆 💪 🔗 🤙 🔠 🔁 (🎲 💗 🕰) 🎏 📨 ↩️ ⚙️ "💾" 💲, 👆 💪 ⚒ 🔢 `use_cache=False` 🕐❔ ⚙️ `Depends`: ```Python hl_lines="1" async def needy_dependency(fresh_value: str = Depends(get_value, use_cache=False)): return {"fresh_value": fresh_value} ``` ## 🌃 ↖️ ⚪️➡️ 🌐 🎀 🔤 ⚙️ 📥, **🔗 💉** ⚙️ 🙅. 🔢 👈 👀 🎏 *➡ 🛠️ 🔢*.
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 06 20:36:54 UTC 2024 - 3.3K bytes - Viewed (0) -
docs/de/docs/tutorial/dependencies/sub-dependencies.md
//// tab | Python 3.8+ ```Python hl_lines="1" async def needy_dependency(fresh_value: Annotated[str, Depends(get_value, use_cache=False)]): return {"fresh_value": fresh_value} ``` //// //// tab | Python 3.8+ nicht annotiert
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 06 20:36:54 UTC 2024 - 6.2K bytes - Viewed (0) -
docs/zh/docs/tutorial/dependencies/sub-dependencies.md
在高级使用场景中,如果不想使用「缓存」值,而是为需要在同一请求的每一步操作(多次)中都实际调用依赖项,可以把 `Depends` 的参数 `use_cache` 的值设置为 `False` : ```Python hl_lines="1" async def needy_dependency(fresh_value: str = Depends(get_value, use_cache=False)): return {"fresh_value": fresh_value} ``` ## 小结 千万别被本章里这些花里胡哨的词藻吓倒了,其实**依赖注入**系统非常简单。 依赖注入无非是与*路径操作函数*一样的函数罢了。
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 06 20:36:54 UTC 2024 - 3.2K bytes - Viewed (0) -
fastapi/dependencies/models.py
response_param_name: Optional[str] = None background_tasks_param_name: Optional[str] = None security_scopes_param_name: Optional[str] = None security_scopes: Optional[List[str]] = None use_cache: bool = True path: Optional[str] = None cache_key: Tuple[Optional[Callable[..., Any]], Tuple[str, ...]] = field(init=False) def __post_init__(self) -> None:
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sat Aug 31 20:19:30 UTC 2024 - 1.5K bytes - Viewed (0) -
tests/test_dependency_cache.py
): return {"counter": count, "subcounter": subcount} @app.get("/sub-counter-no-cache/") async def get_sub_counter_no_cache( subcount: int = Depends(super_dep), count: int = Depends(dep_counter, use_cache=False), ): return {"counter": count, "subcounter": subcount} @app.get("/scope-counter") async def get_scope_counter( count: int = Security(dep_counter),
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Tue Aug 23 13:30:24 UTC 2022 - 2.7K bytes - Viewed (0) -
docs/ja/docs/tutorial/dependencies/sub-dependencies.md
高度なシナリオでは、「キャッシュされた」値を使うのではなく、同じリクエストの各ステップ(おそらく複数回)で依存関係を呼び出す必要があることがわかっている場合、`Depens`を使用する際に、`use_cache=False`というパラメータを設定することができます。 ```Python hl_lines="1" async def needy_dependency(fresh_value: str = Depends(get_value, use_cache=False)): return {"fresh_value": fresh_value} ``` ## まとめ ここで使われている派手な言葉は別にして、**依存性注入** システムは非常にシンプルです。
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 06 20:36:54 UTC 2024 - 4.4K bytes - Viewed (0)