GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — opencode-route-proxy: known-100% seating gate — exclude legs whose binding quota window is known exhausted until reset (#4370c) · Issue #5295 · developing-today/code

opencode-route-proxy: known-100% seating gate — exclude legs whose binding quota window is known exhausted until reset (#4370c) #5295

New issue
Copy link
New issue
Copy link
Closed
#5296
Closed
opencode-route-proxy: known-100% seating gate — exclude legs whose binding quota window is known exhausted until reset (#4370c)#5295
#5296
Copy link
Labels
kind/bugSomething isn't working (prefixed form of the classic bug label)priority/highImportant and time-sensitivetask/small-fixQueue packet kind: bounded fix with reproduction and targeted tests

Description

@dezren39
dezren39
opened on Nov 4, 2026
Issue body actions

opencode-route-proxy: known-100% seating gate — exclude legs whose binding quota window is known exhausted until reset (#4370 acceptance (c))

Implementation slice scoped by triage task 8950 (lane W, 2026-11-04) extending #3325 leg-shedding to the #4370 death classes. Findings and full evidence are on #3325 (task 8950 comment) and #4370.

Problem (verified at main, blob 70f01618, bin/opencode-route-proxy.mjs, 1095 lines)

  • Seating has no known-100% gate. demotedPairs (lines ~330–345) learns only from the attempt ledger (≥3 quota failures in 4 h), and applyDemotion (lines ~662–670) reorders demoted pairs to the back — it never excludes them.
  • A leg whose binding window is already known to be at 100% with a future reset (cline-pass monthly, fleet session deaths rotated legs: provider.transport timeouts on the gpt-6-luna leg and cline-pass leg wall/rate-limit deaths are not tracked by #3325 #4370: 11 sessions killed 2026-11-01) is a normal first-choice candidate until it has failed three times.

Scope

  • Seating-time gate in bin/opencode-route-proxy.mjs: a (provider, model) pair whose binding quota window is known exhausted (ledger quota detail carrying a future reset, or an equivalent known-100% record the proxy already stores) is EXCLUDED from candidates until that reset — the credential-less exclusion pattern (opencode-route-proxy: opendesign leaves sit in pools but the provider's credential is inactive — walks burn attempts and surface a misleading auth error #3228).
  • Fail-safe: if exclusion would empty the route, keep current demoted order rather than hard-failing; record the gate decision in existing diagnostics.
  • Tests with the pinned-now clock (OPENCODE_ROUTE_PROXY_NOW_MS): known-100% pair excluded while a live pair exists; pair returns after reset; all-exhausted route still walks in demoted order.

Out of scope: external quota-service reads at request time, demotion threshold changes, transport timeouts (companion slice), in-stream shedding (task 8932).

Acceptance criteria

  • Sessions are not seated on a known-100% leg while any non-exhausted candidate exists (fleet session deaths rotated legs: provider.transport timeouts on the gpt-6-luna leg and cline-pass leg wall/rate-limit deaths are not tracked by #3325 #4370 acceptance (c)).
  • Gate is per (provider, model) and lifts automatically at the recorded reset.
  • Verified by proxy tests plus a route-attempt ledger extract in the PR showing a known-exhausted pair skipped.

Refs: #4370 (acceptance (c)), #3325, task 8950.

Activity

  1. dezren39
    added
    kind/bugSomething isn't working (prefixed form of the classic bug label)
    task/small-fixQueue packet kind: bounded fix with reproduction and targeted tests
    priority/highImportant and time-sensitive
    work/assignedQueue worker lifecycle state
    queue/claimedQueue worker lifecycle state
    status/in-progressQueue worker lifecycle state
    on Nov 4, 2026
  2. dezren39 commented on Nov 4, 2026

    @dezren39
    dezren39
    on Nov 4, 2026
    MemberAuthor
    More actions

    🤖 Agent note · picked up → PR opened (task 9239)

    • Agent: repo-worker-code, lane code-c
    • Task: task 9239 (small_fix) for issue opencode-route-proxy: known-100% seating gate — exclude legs whose binding quota window is known exhausted until reset (#4370c) #5295 (fleet session deaths rotated legs: provider.transport timeouts on the gpt-6-luna leg and cline-pass leg wall/rate-limit deaths are not tracked by #3325 #4370 acceptance (c))
    • PR: fix(route-proxy): known-100% seating gate — exclude pairs with a future quota reset (#5295) #5296 — fix(route-proxy): known-100% seating gate — exclude pairs with a future quota reset (#5295) #5296 (branch queue/9239-5295-known100-gate, commit 8f0bef24e)

    Implemented: knownExhaustedPairs + applyKnownExhaustedGate in bin/opencode-route-proxy.mjs — a pair whose latest quota-bearing ledger failure carries a future reset (Retry-After-derived or absolute) and no later success is excluded from candidates after demotion; fail-safe keeps the demoted order when exclusion would empty the route; decisions logged to the proxy's stderr diagnostics; clock via nowMs() so OPENCODE_ROUTE_PROXY_NOW_MS pins it.

    Verified on the laptop: node --test bin/opencode-route-proxy.test.mjs — 31/31 pass, including 4 new pinned-clock tests (exclusion with ledger extract, return after reset, all-exhausted bypass, success-clears-gate). This issue closes via the PR's Fixes #5295 on merge.

  3. dezren39
    added 3 commits that reference this issue on Nov 4, 2026

    fix(route-proxy): Codex round on #5295 — credential-aware gate fallba…

    e1a9504

    fix(route-proxy): Codex round 2 on #5295 — order gate observations by…

    f749cd1

    Merge pull request #5296 from developing-today/queue/9239-5295-known1…

    9c8f91e
  4. dezren39
    closed this as completedin #5296on Nov 4, 2026
  5. dezren39 commented on Nov 4, 2026

    @dezren39
    dezren39
    on Nov 4, 2026
    MemberAuthor
    More actions

    🤖 Agent note · done (task 9239)

    • Agent: repo-worker-code, lane code-c
    • Task: task 9239 (small_fix) — complete, outcome fixed_merged
    • PR: fix(route-proxy): known-100% seating gate — exclude pairs with a future quota reset (#5295) #5296 MERGED at 9c8f91e48477c7908f55bf50ce5fff3c9ee87414; this issue closed by its Fixes #5295.

    Delivered: the known-100% seating gate in bin/opencode-route-proxy.mjs (#4370 acceptance (c)): pairs whose latest quota-bearing ledger failure carries a future reset and no later success are excluded at seating time; fail-safe keeps the demoted order when no credentialed candidate survives; decisions on the proxy's stderr diagnostics; clock via nowMs().

    Verification: node --test bin/opencode-route-proxy.test.mjs — 34/34 on the laptop, including 7 new pinned-clock gate tests. Codex review: three rounds — credential-aware fallback (P2), receipt-anchored Retry-After (P2), completion-time ordering (P2) — all fixed with regression tests and replied on-thread; final round completed with no findings.

    Claim labels cleared with this note.

  6. dezren39
    removed
    status/in-progressQueue worker lifecycle state
    queue/claimedQueue worker lifecycle state
    work/assignedQueue worker lifecycle state
    on Nov 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind/bugSomething isn't working (prefixed form of the classic bug label)priority/highImportant and time-sensitivetask/small-fixQueue packet kind: bounded fix with reproduction and targeted tests

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      You are visitor 01402775 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.