Open
Description
Version
0.25
Stack traces
ValueError: sleep length must be non-negative
File "threading.py", line 864, in run
self._target(*self._args, **self._kwargs)
File "batch.py", line 86, in renew_message_visibility
time.sleep((cur_time + interval) - time.time())
Additional Context
There is a thread that is responsible for renewing the lease on a message in the SQS queue to make sure that other workers don't receive this message. This thread is meant to run once every 15 seconds to renew the lease for another 15 seconds. The fact that the sleep is negative indicates that something in the loop took longer than 15 seconds. The main suspect is that the shared lock is not being released by the main thread for some reasonn.