diff --git a/CHANGELOG.md b/CHANGELOG.md index 79c75068..de5423c9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,8 +1,12 @@ # Changelog +## development + +- Fix compatibility with httpx. (#291) + ## 0.1.1 (2nd Nov, 2024) -- FIx typig extensions nor found. (#290) +- Fix typing extensions not found. (#290) ## 0.1.0 (2nd Nov, 2024) diff --git a/hishel/_async/_transports.py b/hishel/_async/_transports.py index 49556458..60c41de0 100644 --- a/hishel/_async/_transports.py +++ b/hishel/_async/_transports.py @@ -152,7 +152,7 @@ async def handle_async_request(self, request: Request) -> Response: # Controller has determined that the response needs to be re-validated. assert isinstance(res.stream, tp.AsyncIterable) revalidation_request = Request( - method=res.method, + method=res.method.decode(), url=normalized_url(res.url), headers=res.headers, stream=AsyncCacheStream(res.stream), diff --git a/hishel/_sync/_transports.py b/hishel/_sync/_transports.py index bbf1ac06..4aea1e07 100644 --- a/hishel/_sync/_transports.py +++ b/hishel/_sync/_transports.py @@ -152,7 +152,7 @@ def handle_request(self, request: Request) -> Response: # Controller has determined that the response needs to be re-validated. assert isinstance(res.stream, tp.Iterable) revalidation_request = Request( - method=res.method, + method=res.method.decode(), url=normalized_url(res.url), headers=res.headers, stream=CacheStream(res.stream), diff --git a/pyproject.toml b/pyproject.toml index 4c95130b..2e7efb8a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -29,7 +29,7 @@ classifiers = [ "Topic :: Internet :: WWW/HTTP", ] dependencies = [ - "httpx>=0.22.0", + "httpx>=0.28.0", ] [project.optional-dependencies] diff --git a/requirements.txt b/requirements.txt index d3762f34..b49b0917 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,7 +1,7 @@ -e .[yaml,redis,sqlite,s3] # linting -ruff==0.3.0 +ruff==0.6.3 mypy==1.10.0 # docs