RequestException Class — requests Architecture
Architecture documentation for the RequestException class in exceptions.py from the requests codebase.
Entity Profile
Dependency Diagram
graph TD 81e04ff9_ba51_0f07_a46e_3550ec714f38["RequestException"] f4a2f4ac_0336_89fc_eb3c_2c88c34f05a8["exceptions.py"] 81e04ff9_ba51_0f07_a46e_3550ec714f38 -->|defined in| f4a2f4ac_0336_89fc_eb3c_2c88c34f05a8 6f26aa13_d995_0b75_c861_c8d4ed214509["__init__()"] 81e04ff9_ba51_0f07_a46e_3550ec714f38 -->|method| 6f26aa13_d995_0b75_c861_c8d4ed214509
Relationship Graph
Source Code
src/requests/exceptions.py lines 13–25
class RequestException(IOError):
"""There was an ambiguous exception that occurred while handling your
request.
"""
def __init__(self, *args, **kwargs):
"""Initialize RequestException with `request` and `response` objects."""
response = kwargs.pop("response", None)
self.response = response
self.request = kwargs.pop("request", None)
if response is not None and not self.request and hasattr(response, "request"):
self.request = self.response.request
super().__init__(*args, **kwargs)
Domain
Defined In
Source
Frequently Asked Questions
What is the RequestException class?
RequestException is a class in the requests codebase, defined in src/requests/exceptions.py.
Where is RequestException defined?
RequestException is defined in src/requests/exceptions.py at line 13.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free