mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-10-01 23:43:46 +08:00
requests: Use the Any trick in HTTPError (#11207)
This commit is contained in:
1 parent
3edfd9037c
commit
3ede0565d1
1 file changed
+7
-1
@@ -1,3 +1,5 @@
|
||||
from typing import Any
|
||||
|
||||
from urllib3.exceptions import HTTPError as BaseHTTPError
|
||||
|
||||
from .models import Request, Response
|
||||
@@ -12,7 +14,11 @@ class RequestException(OSError):
|
||||
|
||||
class InvalidJSONError(RequestException): ...
|
||||
class JSONDecodeError(InvalidJSONError): ...
|
||||
class HTTPError(RequestException): ...
|
||||
|
||||
class HTTPError(RequestException):
|
||||
request: Request | PreparedRequest | Any
|
||||
response: Response | Any
|
||||
|
||||
class ConnectionError(RequestException): ...
|
||||
class ProxyError(ConnectionError): ...
|
||||
class SSLError(ConnectionError): ...
|
||||
|
||||
Reference in new issue
Block a user