mirror of
https://github.com/stevenrobertson/cuburn.git
synced 2025-04-21 09:01:31 -04:00
Fix retry
This commit is contained in:
parent
c9693b12ae
commit
348525e036
@ -179,8 +179,11 @@ def run_jobs(r, rev, jobs):
|
|||||||
waiting.remove(sidx)
|
waiting.remove(sidx)
|
||||||
if sidx in retry:
|
if sidx in retry:
|
||||||
retry.remove(sidx)
|
retry.remove(sidx)
|
||||||
|
if sidx in pending:
|
||||||
pending.pop(sidx)
|
pending.pop(sidx)
|
||||||
if retry and retry[0] < sidx:
|
else:
|
||||||
|
print 'Got two responses for %d' % sidx
|
||||||
|
if retry and retry[0] < sidx - 2 * QUEUE_LENGTH:
|
||||||
# TODO: better exception
|
# TODO: better exception
|
||||||
raise ValueError("Double retry!")
|
raise ValueError("Double retry!")
|
||||||
expired, waiting[:] = partition(lambda w: w < sidx - QUEUE_LENGTH,
|
expired, waiting[:] = partition(lambda w: w < sidx - QUEUE_LENGTH,
|
||||||
|
Loading…
Reference in New Issue
Block a user