Skip to content
Myr

exceptions.py

This file

Path

httpcore/exceptions.py

71 lines · 1.1 KiB · Python

Last changed by

RedirectionsTom Christiebefore adoption041813b

History of this file

Take it

StuffTom Christiebefore adoption30530d4

lines 1–18why, one step back
1class Timeout(Exception):
2 """3 A base class for all timeouts.4 """567class ConnectTimeout(Timeout):8 """9 Timeout while establishing a connection.10 """111213class ReadTimeout(Timeout):14 """15 Timeout while reading response data.16 """1718

Stream refactoring and HTTP/2 test caseTom Christiebefore adoptiona44190f

lines 19–24why, one step back
19class WriteTimeout(Timeout):
20 """21 Timeout while writing request data.22 """2324

StuffTom Christiebefore adoption30530d4

lines 25–30why, one step back
25class PoolTimeout(Timeout):
26 """27 Timeout while waiting to acquire a connection from the pool.28 """2930

RedirectionsTom Christiebefore adoption041813b

line 31why, one step back
31class RedirectError(Exception):

AdaptersTom Christiebefore adoptionfab6fcd

line 32why, one step back
32 """

RedirectionsTom Christiebefore adoption041813b

lines 33–38why, one step back
33 Base class for HTTP redirect errors.
34 """353637class TooManyRedirects(RedirectError):38 """

AdaptersTom Christiebefore adoptionfab6fcd

line 39why, one step back
39 Too many redirects.

RedirectionsTom Christiebefore adoption041813b

lines 40–45why, one step back
40 """
414243class RedirectLoop(RedirectError):44 """45 Infinite redirect loop.

AdaptersTom Christiebefore adoptionfab6fcd

lines 46–48why, one step back
46 """
4748

Merge pull request #17 from encode/close-keepalive-connectionsTom Christiebefore adoption91a2a1b

line 49why, one step back
49class ProtocolError(Exception):

StuffTom Christiebefore adoption30530d4

line 50why, one step back
50 """

Merge pull request #17 from encode/close-keepalive-connectionsTom Christiebefore adoption91a2a1b

line 51why, one step back
51 Malformed HTTP.

StuffTom Christiebefore adoption30530d4

lines 52–66why, one step back
52 """
535455class StreamConsumed(Exception):56 """57 Attempted to read or stream response content, but the content has already58 been streamed.59 """606162class ResponseClosed(Exception):63 """64 Attempted to read or stream response content, but the request has been65 closed without loading the body.66 """

Rollin'Tom Christiebefore adoption8a29a0a

lines 67–71why, one step back
67
6869class InvalidURL(Exception):70 """71 """