logoalt Hacker News

KaiserProyesterday at 2:49 PM5 repliesview on HN

Why would you want to use HTTPX2 over say requests?


Replies

12_throw_awayyesterday at 11:54 PM

Async. And it comes with WSGI and ASGI transport adapters [1], which are amazing for testing/debugging with the client and server in a single process. And I personally find the httpx API is much cleaner and more composable, but ymmv.

[1] https://www.python-httpx.org/advanced/transports/#wsgi-trans...

deathanatostoday at 1:59 AM

Since it clearly intends to satisfy the async use case, I wish you'd've phrased this as "over aiohttp".

imp0catyesterday at 6:35 PM

You probably want to use pretty much anything over requests for performance reasons.

oerstedyesterday at 3:42 PM

async