You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit a59bb68
Browse filesBrowse the repository at this point in the historyBrowse files
## Description
This PR introduces support to client-passed `httpx2` connection via
`httpx_compat`
It is backward compatible, which means that passing `httpx` is also
valid and exceptions/typing are properly handled
The compat layer exports catch-tuples for except/isinstance, type
aliases for annotations, and `httpx_lib`
The only use of `httpx` is left in 2 places:
- When client didn't provide their own connection (so we are leaving it
as is)
- When checking the status codes (httpx and httpx2 behave the same way
here)
## Tests
- Restructured tests, so that they use `httpx_lib` from `httpx_compat`
- Marked the 35 files whose behavior depends on the installed lib with
`@pytest.mark.httpx2.` This includes files that never mention httpx
themselves: `starlette.testclient` picks `httpx2` when it is installed,
so anything using TestClient is affected too.
- Added a CI job that installs the new httpx2 dependency group and
reruns those tests. The default matrix installs only dev, so it stays an
httpx-only environment.
Release-As: 1.4.0
refers to a2aproject#1288
0 commit comments