aiobotocore icon indicating copy to clipboard operation
aiobotocore copied to clipboard

Retry not working for ConnectTimeoutError

Open dacevedo12 opened this issue 2 years ago • 3 comments

Describe the bug ConnectTimeoutError is not being retried

In async def _needs_retry (endpoint.py), when the argument caught_exception is botocore.exceptions.ConnectTimeoutError raised by async def send (httpsession.py), handler_response is always None, so the retry mechanism won't work.

pip freeze results I'm using aioboto3 9.6.0 + aiobotocore 2.3.0

Environment:

  • Python Version: 3.9
  • OS name and version: nixos

dacevedo12 avatar Aug 03 '22 17:08 dacevedo12

thank you will look asap

thehesiod avatar Aug 25 '22 16:08 thehesiod

would you be able to compare against the same underlying version of botocore to see how we differ? Or if you can provide a test case to ensure I'm fixing the right bug

thehesiod avatar Aug 25 '22 16:08 thehesiod

I'm not familiarized with the inner workings of boto, but I found this test case: https://github.com/boto/botocore/blob/develop/tests/unit/test_retryhandler.py#L267

Perhaps they intend to retry read timeouts but not connect timeouts, which is weird because they consider it as a timeout in other parts of the code https://github.com/boto/botocore/blob/develop/botocore/retries/standard.py#L483

dacevedo12 avatar Aug 25 '22 20:08 dacevedo12

can you re-try with latest version?

thehesiod avatar Aug 29 '23 16:08 thehesiod

Been a while since I last saw the error, let's close

dacevedo12 avatar Aug 29 '23 16:08 dacevedo12