]> git.ipfire.org Git - thirdparty/httpx.git/commitdiff
Merge branch 'master' into async-dependencies-optional
authorTom Christie <tom@tomchristie.com>
Thu, 28 Dec 2023 14:21:57 +0000 (14:21 +0000)
committerGitHub <noreply@github.com>
Thu, 28 Dec 2023 14:21:57 +0000 (14:21 +0000)
1  2 
httpx/_transports/asgi.py
httpx/_transports/default.py
httpx/_utils.py
pyproject.toml
requirements.txt

Simple merge
index fd53c77fb99a8de95218c73938e676ab4dd969b9,14a087389a8ba910a6b4d88ef69527ba9eb335c0..4f6bb94084a5902ed7719faafc7cdaaf3a4eb173
@@@ -269,14 -272,8 +272,15 @@@ class AsyncHTTPTransport(AsyncBaseTrans
          retries: int = 0,
          socket_options: typing.Optional[typing.Iterable[SOCKET_OPTION]] = None,
      ) -> None:
 +        try:
 +            import sniffio  # noqa: F401
 +        except ImportError:  # pragma: nocover
 +            raise RuntimeError(
 +                "Using httpx in async mode, but neither httpx['asyncio'] or asyncio['trio'] is installed."
 +            )
 +
          ssl_context = create_ssl_context(verify=verify, cert=cert, trust_env=trust_env)
+         proxy = Proxy(url=proxy) if isinstance(proxy, (str, URL)) else proxy
  
          if proxy is None:
              self._pool = httpcore.AsyncConnectionPool(
diff --cc httpx/_utils.py
Simple merge
diff --cc pyproject.toml
Simple merge
index d1065ee37792db18f67331a4d3e631d73ecf9630,3fb85ca726ed8d0f2f9288edbf1105542ca1abaa..0718c1370e40be10ebb5ee466de8b5a6935f26de
@@@ -19,13 -18,12 +18,11 @@@ build==1.0.
  twine==4.0.2
  
  # Tests & Linting
- black==23.9.1
  coverage[toml]==7.3.0
- cryptography==41.0.4
+ cryptography==41.0.7
  mypy==1.5.1
- types-certifi==2021.10.8.2
- pytest==7.4.2
- ruff==0.0.291
- trio-typing==0.8.0
+ pytest==7.4.3
+ ruff==0.1.6
+ trio==0.22.2
 -trio-typing==0.10.0
  trustme==1.1.0
- uvicorn==0.22.0
+ uvicorn==0.24.0.post1