From a5b8858f0eff1fb425048d1fbb3f8c7df7946bc7 Mon Sep 17 00:00:00 2001 From: Kar Petrosyan <92274156+karpetrosyan@users.noreply.github.com> Date: Sun, 23 Jun 2024 18:16:06 +0400 Subject: [PATCH] Version 0.0.29 (#244) * Version 0.0.29 * changelog --------- Co-authored-by: Karen Petrosyan --- CHANGELOG.md | 4 ++++ docs/advanced/extensions.md | 5 +++-- hishel/__init__.py | 2 +- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e629913..1fe0265 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog +## 0.0.29 (23th June, 2024) + +- Documentation hotfix. (#244) + ## 0.0.28 (23th June, 2024) - Add `revalidated` response extension. (#242) diff --git a/docs/advanced/extensions.md b/docs/advanced/extensions.md index 1f1395f..fcffe10 100644 --- a/docs/advanced/extensions.md +++ b/docs/advanced/extensions.md @@ -62,11 +62,12 @@ True ### revalidated -Every response will have a revalidated extension that indicates whether the response has been revalidated or not. +Every response will have a `revalidated` extension that indicates whether the response has been revalidated or not. !!! note Note that a response could have `revalidated` set to `True` even when `from_cache` is set to `False`. This occurs when the cached entry has been updated and a new entry is downloaded during revalidation. +```python >>> import hishel >>> client = hishel.CacheClient() >>> response = client.get("https://www.example.com/endpoint_that_is_fresh") @@ -75,7 +76,7 @@ False >>> response = client.get("https://www.example.com/endpoint_that_is_stale") >>> response.extensions["revalidated"] True - +``` ### cache_metadata diff --git a/hishel/__init__.py b/hishel/__init__.py index 439ada9..f0e2ff6 100644 --- a/hishel/__init__.py +++ b/hishel/__init__.py @@ -14,4 +14,4 @@ def install_cache() -> None: # pragma: no cover httpx.Client = CacheClient # type: ignore -__version__ = "0.0.28" +__version__ = "0.0.29"