Repository navigation
Description
Problem
The Service (roadmap-service) stays at its own budget of 2000 GitHub requests per hour all day. Measured on 2026-11-07 with Prometheus:
increase(devops_cli_github_requests_total{job="roadmap-service"}[1h])is 2020. In the last 12 hours it was 1800 to 1970 in each hour.- 881 of these (44%) have status 304. By status: 200 = 887, 304 = 880, none = 264.
- The Service log has this warning 66 times in 24 hours: "The Service sent 2000 GitHub requests in the last hour, and its budget is 2000: no round starts until the window has room."
- Rounds (refine, stage, alternatives, implement) start late or not at all, so the pipeline starves.
GitHub documents that a conditional request that gets a 304 answer does not count against the primary rate limit (docs.github.com, "Best practices for using the REST API", "Use conditional requests"). The budget protects the primary rate limit of the App installation (minimum 5,000 per hour, "Rate limits for the REST API"). RequestBudget.admit (src/devops_cli/server/service.py) counts a request before it is sent, so it counts each 304 answer.
Expected
The budget counts the requests that GitHub counts. A request that gets a 304 answer leaves the budget. A request with no answer still counts: GitHub may have received it, and a gh command has no status. The metric devops_cli_github_requests_total stays as it is: it counts every request, with a status label.
Acceptance criteria
- A test shows that a request which gets a 304 answer is not in the budget after the answer, and that a 200 answer and a request with no answer stay in it.
- The cost of a round, which sets the poll cadence, does not include the 304 answers.
docs/TELEMETRY.mdsays what the budget counts.
Existing tool considered
The GitHub conditional request (#3497) already exists. This change only reads its status at the budget. No library is needed.
Related
Related: #3672 (an idle repository polls less often), #3497, #2547.
Activity
dan-petty commentedon Nov 7, 2026
Intake placed this item to the backlog: intake puts every new item in the backlog. A person plans the milestones.
fixprefix of the title gives the type.(service)scope of the title gives the scope.The Service starves and rounds do not start, blocking the pipeline.The Service cannot process work until the budget stops counting 304 responses.The change reads the response status in one method and adds one test.Both fix RequestBudget in service.py, but #2547 fixes when the budget is enforced and this fixes what the budget counts.devops-cli-service commentedon Nov 7, 2026
Released in v0.78.0: https://github.com/dan-petty/devops-cli/releases/tag/v0.78.0
devops-cli-service commentedon Nov 7, 2026
Live since 2026-11-07 12:09 UTC