-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PYTHON-2560 Retry KMS requests on transient errors #2024
Conversation
Failures look relevant: "FAILURE: AssertionError: "kms.us-east-1.amazonaws.com:12345" does not match "KMS request failed after 3 retries due to a network error" ()" |
Ah this is caused by the problem described in: https://jira.mongodb.org/browse/MONGOCRYPT-752 With this new feature, the user gets a too vague error message that just says "KMS request failed after 3 retries due to a network error" so we can't assert on the error message for those other tests now. Without libmongocrypt changes, we'll need to introduce a new context object to store the previous exception error message. |
It turns out to be quite simple to include the last error message. I didn't realize the error comes from mongocrypt_kms_ctx_fail. Tests are passing locally now. |
[2024/12/03 16:50:30.134] FAILURE: AssertionError: "kms.us-east-1.amazonaws.com:12345" does not match "KMS request failed after 3 retries due to a network error, last attempt failed with: [Errno 111] Connection refused" () |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
PYTHON-2560 Retry KMS requests on transient errors
Depends on: