Skip to content
Myr

Drop URLLib3Dispatch compat shim (#972)

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Tom Christie · committed by GitHub · parent 225f1e2 · Browse files · 1 file+1 added−25 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+1 added−25 removed

  • other:+1 added−25 removed

1 file+1 added−25 removed

modified:httpx/_transports/urllib3.py+1 added-25 removed
5 unmodified lines
67from .._config import Proxy, SSLConfig8from .._content_streams import ByteStream, IteratorStream9from .._types import CertTypes, VerifyTypes10from .._utils import as_network_error, warn_deprecated10from .._utils import as_network_error1112try:13 import urllib314 from urllib3.exceptions import MaxRetryError, SSLError
129 unmodified lines
144 return (b"HTTP/1.1", status_code, conn.reason, headers, response_stream)145146 def close(self) -> None:147 self.pool.clear()148149150class URLLib3Dispatch(URLLib3Transport):151 def __init__(152 self,153 *,154 proxy: Proxy = None,155 verify: VerifyTypes = True,156 cert: CertTypes = None,157 trust_env: bool = None,158 pool_connections: int = 10,159 pool_maxsize: int = 10,160 pool_block: bool = False,161 ):162 warn_deprecated("URLLib3Dispatch is deprecated, please use URLLib3Transport")163 super().__init__(164 proxy=proxy,165 verify=verify,166 cert=cert,167 trust_env=trust_env,168 pool_connections=pool_connections,169 pool_maxsize=pool_maxsize,170 pool_block=pool_block,171 )