[#344] 🐛 - Throttle workflow queue polling and increase workflow timeouts - #345
Conversation
…outs: bound rate-limit retries
|
To preview the documentation for this pull request, visit the following URL:
|
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## develop #345 +/- ##
===========================================
+ Coverage 90.94% 92.58% +1.64%
===========================================
Files 135 467 +332
Lines 6251 8229 +1978
Branches 1338 1643 +305
===========================================
+ Hits 5685 7619 +1934
- Misses 172 229 +57
+ Partials 394 381 -13
🚀 New features to boost your workflow:
|
🐛 Bugfix Actions
Debug log🚀 Happy coding! Made with ❤️ by vypdev/copilot |
🐛 Bugfix Actions
Debug log🚀 Happy coding! Made with ❤️ by vypdev/copilot |


📌 Summary
Improves the repository-wide Copilot workflow queue to withstand bursts without exhausting GitHub API limits, while preserving strict sequential execution and allowing long queues to drain reliably.
🎯 Related Issues / Tickets
🧩 Scope of Changes
Added:
Updated:
Removed:
Refactored:
🛠️ Technical Details
Retry-Afterandx-ratelimit-reset, with bounded fallback backoff when headers are unavailable.concurrencyblock, preventing cancellation or replacement of queued runs.🔍 How to Test
Run the deterministic queue and retry tests:
corepack pnpm@10.12.4 exec jest \ src/application/usecases/workflow/__tests__/wait_for_previous_workflow_runs_use_case.test.ts \ src/data/repository/workflow/__tests__/active_previous_workflow_runs_repository.test.ts \ src/data/repository/workflow/__tests__/workflow_runs_retry_policy.test.ts \ src/tooling/__tests__/validate_workflow_contract.test.tsRun the project quality gates:
Confirm the workflow contract validator accepts both
.github/workflows/andsetup/workflows/, including the 120-minute queue-job timeouts and absence of mutation-workflow concurrency settings.🧪 Test Coverage
📸 Screenshots / Recordings (UI changes only)
Not applicable — no UI changes.
🚀 Deployment Notes
Details: Generated action and CLI bundles are included and should be released through the normal action release process. Setup workflow templates are synchronized with the active workflows.
🔒 Security Considerations
Provider error details are no longer interpolated into logs or externally visible failures. Diagnostic logging is limited to retry reason, attempt, delay, and reset metadata.
📈 Performance Impact
Reduces API fan-out from multiple status-specific queries to one paginated traversal per poll and increases polling intervals adaptively. Complete pagination and retry restarts remain necessary to preserve queue correctness.
📝 Notes for Reviewers
Please pay particular attention to the fail-closed behavior, later-page pagination coverage, rate-limit header handling, and synchronization between active and setup workflow contracts.
✅ Checklist
📚 Additional Context
The queue remains repository-wide across the seven Copilot/Task mutation workflows so intermediate issue, branch, and release mutations are never cancelled, skipped, or overwritten.