Discussions

Ask a Question
Back to All

Handling 500 Errors from Rose Rocket API

Hi,

Occasionally our API calls to Rose Rocket will fail with 500 errors, like the following

[ERROR] HTTPError: 500 Server Error: Internal Server Error for url: https://platform.roserocket.com/api/v1/manifests/xxxxxxxxxxxxxxxxxxxxx
Traceback (most recent call last):
  File "/var/task/get_data.py", line 164, in webhook_handler
    manifest = get_manifest(headers, body['manifest_id'])
  File "/var/task/get_data.py", line 350, in get_manifest
    res.raise_for_status()
  File "/var/runtime/requests/models.py", line 953, in raise_for_status
    raise HTTPError(http_error_msg, response=self)

What is the proper way to catch and handle these exceptions? Should they be retried? Is there any additional information we can find in the response to help troubleshoot the issue?