(self, status=None, reason=None, http_resp=None)
| 103 | class ApiException(OpenApiException): |
| 104 | |
| 105 | def __init__(self, status=None, reason=None, http_resp=None): |
| 106 | if http_resp: |
| 107 | self.status = http_resp.status |
| 108 | self.reason = http_resp.reason |
| 109 | self.body = http_resp.data |
| 110 | self.headers = http_resp.getheaders() |
| 111 | else: |
| 112 | self.status = status |
| 113 | self.reason = reason |
| 114 | self.body = None |
| 115 | self.headers = None |
| 116 | |
| 117 | def __str__(self): |
| 118 | """Custom error messages for exception""" |
nothing calls this directly
no test coverage detected