- Sponsor
-
Notifications
You must be signed in to change notification settings - Fork 198
Open
Description
aiohttp does not support http/2, and has no immediate plans to: aio-libs/aiohttp#320 aio-libs/aiohttp#863
likewise moto does not have plans to, as werkzeug does not support it: getmoto/moto#8904
But AWS does support it, as does httpx, so aibotocore should be able to when running with httpx as the backend. For tests it should be possible to run a local proxy server such as nginx or nghttpx to translate requests from http/2 before they're forwarded to moto.
I struggled to make progress with this in #1085, but @thehesiod noted
it's critical when using http/2 w/ httpx to not have it pre-populate the Connection header when creating the Client
Activity
jakkdl commentedon May 28, 2025
this should also include a http/2 + SigV4 test (there's currently a
test_presign_sigv4
intest_basic_s3
)https://github.com/aio-libs/aiobotocore/pull/1085/files/6daaa79983a468003b7429fd7d92a9c1a63e8954#r2109117717
Andarius commentedon Jun 30, 2025
As a side note, to be future proof (HTTP/3), it could be interesting to investigate libs like niquests.
I've been hitting some issues with httpx regarding SSE when working with LLMs, so I switched most of my projects to niquests without any real pain so fat.