You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Set the redis lock expire time according to the ETA countdown if "default_timeout" is not given
Change in celery_once.tasks.py:QueueOnce.apply_async
once_timeout = (
once_options.get('timeout')
or self.once.get('timeout')
or self.default_timeout
or self.calc_timeout(options)
or 60 * 60
)
calc_timeout code example
@staticmethod
def calc_timeout(options):
countdown, eta = options.get("countdown"), options.get("eta")
if countdown:
return countdown
elif eta:
return localize(eta, timezone.utc)
The text was updated successfully, but these errors were encountered:
Ed-XCF
changed the title
support calc_timeout for once_timeout
Set the redis lock expire time according to the ETA countdown if "default_timeout" is not given
Mar 16, 2021
Set the redis lock expire time according to the ETA countdown if "default_timeout" is not given
Change in celery_once.tasks.py:QueueOnce.apply_async
calc_timeout code example
The text was updated successfully, but these errors were encountered: