Commit 9b31529
committed
Fix wait_for_workers to allow retry workers to finish before reporting
When Buildkite retries a job, the main queue is already exhausted from
the original run. A retry worker may find unresolved failures via the
error-reports fallback and start re-running them via the Retry queue.
But those tests are not in the Redis running set, so active_workers?
returns false and the summary's wait_for_workers loop exits immediately
on exhausted? — canceling the retry worker before it can clear the
error-report.
Fix: after the main loop exits due to exhausted?, if this is a retry
run (BUILDKITE_RETRY_COUNT > 0) and error-reports are still non-empty,
wait up to inactive_workers_timeout for retry workers to clear them.1 parent 637d7b7 commit 9b31529
2 files changed
Lines changed: 22 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
99 | 99 | | |
100 | 100 | | |
101 | 101 | | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
102 | 107 | | |
103 | 108 | | |
104 | 109 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
39 | 39 | | |
40 | 40 | | |
41 | 41 | | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
42 | 59 | | |
43 | 60 | | |
44 | 61 | | |
| |||
0 commit comments