diff --git a/CHANGES.rst b/CHANGES.rst index 21448ce..dffa5b0 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -1,6 +1,11 @@ Changes ======= +TBR +--- + +* Require to install ``Brotli`` as a dependency. + 0.3.0 (2022-07-29) ------------------ diff --git a/setup.py b/setup.py index 353c5b1..184fcec 100755 --- a/setup.py +++ b/setup.py @@ -27,10 +27,11 @@ def get_version(): install_requires=[ 'requests', 'tenacity', - 'aiohttp >= 3.6.0', + 'aiohttp >= 3.7.3', 'tqdm', 'attrs', 'runstats', + 'brotli', ], classifiers=[ 'Development Status :: 3 - Alpha', diff --git a/zyte_api/aio/client.py b/zyte_api/aio/client.py index 82162eb..164402d 100644 --- a/zyte_api/aio/client.py +++ b/zyte_api/aio/client.py @@ -63,7 +63,7 @@ async def request_raw(self, query: dict, *, retrying = retrying or zyte_api_retrying post = _post_func(session) auth = aiohttp.BasicAuth(self.api_key) - headers = {'User-Agent': user_agent(aiohttp)} + headers = {'User-Agent': user_agent(aiohttp), 'Accept-Encoding': 'br'} response_stats = [] start_global = time.perf_counter()