Skip to content

[#811 re-split 1/2] canary-rollout: collapse run-list enumeration to a cached per-repo fetch #819

Description

@don-petry

Re-split of #811 (2/2 of #803), which timed out at the 2100s action budget bundling the fetch refactor + sync-issues + tests. This is the fetch-refactor half only. Builds on #810 (merged: _run_json backoff + error surfacing).

Scope — scripts/canary-rollout.sh (fetch mechanism only)

Replace the per-workflow gh run list --repo <r> --workflow <wf> enumeration (one call per workflow × per agent × per tier — the burst that trips secondary rate limits) with one paginated gh run list --repo <repo> per repo, cached for the run, then filter to the target workflow locally. Keep _run_json's public contract/return shape identical so callers and #810's backoff are unchanged.

Out of scope

Acceptance criteria

  • Per-evaluation gh run list call count materially reduced (state before/after in the PR).
  • Same promote/block decisions on good data (return shape unchanged).
  • Fails closed; existing canary-rollout bats stay green; add a test for the per-repo cache + local filter.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions