summaryrefslogtreecommitdiffstats
path: root/requests/exceptions.py
diff options
context:
space:
mode:
authorThibaut Horel <thibaut.horel@gmail.com>2013-09-29 05:12:56 -0400
committerThibaut Horel <thibaut.horel@gmail.com>2013-09-29 05:12:56 -0400
commit19346fa9068878af516cdb670bea4f791337507b (patch)
tree54d4fa5a82b2e0305f3b050dc1ebb53ec9d82a5d /requests/exceptions.py
downloadlastfm-19346fa9068878af516cdb670bea4f791337507b.tar.gz
Initial commit
Diffstat (limited to 'requests/exceptions.py')
-rw-r--r--requests/exceptions.py31
1 files changed, 31 insertions, 0 deletions
diff --git a/requests/exceptions.py b/requests/exceptions.py
new file mode 100644
index 0000000..c7b98e6
--- /dev/null
+++ b/requests/exceptions.py
@@ -0,0 +1,31 @@
+# -*- coding: utf-8 -*-
+
+"""
+requests.exceptions
+~~~~~~~~~~~~~~~~~~~
+
+This module contains the set of Requests' exceptions.
+
+"""
+
+class RequestException(Exception):
+ """There was an ambiguous exception that occurred while handling your
+ request."""
+
+class HTTPError(RequestException):
+ """An HTTP error occurred."""
+
+class ConnectionError(RequestException):
+ """A Connection error occurred."""
+
+class SSLError(ConnectionError):
+ """An SSL error occurred."""
+
+class Timeout(RequestException):
+ """The request timed out."""
+
+class URLRequired(RequestException):
+ """A valid URL is required to make a request."""
+
+class TooManyRedirects(RequestException):
+ """Too many redirects."""