1
0
mirror of https://github.com/EDCD/EDMarketConnector.git synced 2025-05-31 23:59:38 +03:00

CAPI: No need to handle HTTP 5xx specially

This will be handled by the `except HTTPError` above.
This commit is contained in:
Athanasius 2021-08-26 15:14:52 +01:00
parent 6c24d9291a
commit 2179936d6f
No known key found for this signature in database
GPG Key ID: AE3E527847057C7D

View File

@ -794,14 +794,6 @@ class Session(object):
self.dump(r)
raise CredentialsError('Redirected back to Auth Server')
# TODO: Shouldn't this be covered by raise_for_status() above ?
elif 500 <= r.status_code < 600:
# Server error. Typically 500 "Internal Server Error" if server is down
logger.debug('500 status back from CAPI')
self.dump(r)
# LANG: Frontier CAPI data retrieval failed with 5XX code
raise ServerError(f'{_("Frontier CAPI server error")}: {r.status_code}')
self.retrying = False
if capi_endpoint == self.FRONTIER_CAPI_PATH_PROFILE and 'commander' not in capi_data: