[Feature] Structured exhausted-combo diagnostics for unattended agent sessions
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 5/5
- Estimated time
- Over a week
- Newbie friendliness
- 25/100
- Issue type
- Feature
- Clarity
- Mostly clear
- Activity status
- Active
- Tech stack
- typescript
- Domain
- backend-api-design
Research direction
Read the existing combo failover and compaction controls referenced in the issue, along with the Responses JSON/SSE error handling paths. Map how eligible targets, retry admission, streaming commits, and cancellation are currently tracked before proposing the typed combo_exhausted contract. Done means reporting an accurate cause only after permitted targets are examined while preserving protocol behavior and preventing retries after visible output or ambiguous side effects.
Written by the indexing model from the issue text.
Description
What are you trying to accomplish?
Make long-running agentic sessions reliably report why a configured failover combo cannot continue, without mistaking a single target error for a globally exhausted combo. Users away from the client need a clear, machine-readable terminal condition that a compatible client can render professionally and use for alerts.
What prevents this today?
In OpenCodex v2.93.0, provider errors are surfaced as raw error text or a last-target refusal after failover. A multi-provider combo can contain different failures at once (provider access denied, quota cooldown, upstream transient, unsupported mandatory-tool wire choice). An HTTP 400/403/429 from one target is not proof all targets lack tokens. Conversely, a final exhausted combo lacks a stable, distinct, cross-provider diagnostic contract suitable for clients to display as an actionable summary.
Real operator observation: long agentic work in a Codex client stopped with Provider error 400: Antigravity invalid request. Separate live testing confirmed a Meta Responses tool_choice=required compatibility 400 when a combo selects Meta; filed as #7964. These are two distinct failure classes and this request must not bypass existing replay/side-effect protections.
Expected behavior
- Keep existing safe retry and failover admission: never retry after committed visible output or ambiguous side effects; do not retry 403 policy restrictions or malformed client requests.
- Only after all eligible and permitted configured targets have been examined, emit a stable typed failure such as
combo_exhaustedwith combo ID, high-level cause classification (quota, permission, capacity, transient, incompatible request, mixed/unknown), number of eligible/attempted targets, and optional bounded retry time derived from trusted provider evidence. Do not expose account IDs, secrets, prompts, or internal config. - Distinguish
all targets quota-exhaustedfrommixed provider causesandno target supports required tooling; do not invent a reason or claim credits are exhausted based solely on an HTTP 400. - Preserve the original client protocol (Responses JSON/SSE terminal semantics) and make the typed error available to the UI, telemetry, and alerting without hardcoding visual elements in the proxy.
- Handle partial streaming, cancellations, cooldown races, account revisions, and late successes; a network retry cannot repeat tool side effects or a committed response.
Suggested operator-facing wording
- Quota-only: “El combo RHODIZ no tiene destinos disponibles por límites de uso. Espera al restablecimiento de cuota o revisa los planes de tus proveedores.”
- Mixed: “El combo RHODIZ no pudo completar la solicitud. Algunos proveedores rechazaron el acceso y otros están limitados. Revisa los destinos o selecciona otro combo compatible.”
- Capability-only: “Ningún destino del combo admite las herramientas obligatorias de esta solicitud.”
The client should choose layout, severity and notification behavior.
Alternatives or workarounds
Operators can parse logs manually or switch combos, but that does not provide reliable unattended diagnostics. Rewriting every upstream error to “out of tokens” would be misleading and dangerous. A documented typed response is backward-compatible if clients without specialized rendering still receive useful concise text.
Version / environment
OpenCodex v2.93.0 Linux, multi-provider Responses failover combos; no secrets or original prompts included. Related issues #7443 (context-specific 400 hops), #7850 (compaction routing), #7964 (Meta required-tool capability).
Checks
- Searched related issues and reviewed the existing combo failover/compaction controls.
- Operator request is a new error-reporting contract, not a claim that all retries are missing.
- No credentials, private account data or conversation contents included.
- Dominant language
- TypeScript
- Stars
- 16.9k
- Forks
- 1.3k
- Avg merge
- 16h 42m
- Merged PRs (30d)
- 695
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from lidge-jun/opencodex
-
bug provider tools
Difficulty 4/5 3-5 days Newbie friendliness 52/100
Maintainers usually reply within 1 day
-
[Bug]: Routed Claude sessions emit call_ tool_use ids, and Remote Control drops their approval cardsOpenbug tools
Difficulty 3/5 1-2 days Newbie friendliness 67/100
lidge-jun/opencodex#8051 · 1 comment ·
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 35/100
lidge-jun/opencodex#8050 · 1 comment · 1 reaction ·
Maintainers usually reply within 1 day
-
account-pool bug
Difficulty 4/5 3-5 days Newbie friendliness 45/100
lidge-jun/opencodex#8042 · 4 comments · 1 reaction ·
Maintainers usually reply within 1 day
-
bug gui proxy service
Difficulty 5/5 Over a week Newbie friendliness 28/100
lidge-jun/opencodex#7967 · 4 comments ·
Maintainers usually reply within 1 day
All issues in lidge-jun/opencodex
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Maintainers usually reply within 1 day
-
enhancement tech debt
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
privatenumber/tsx#866 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
danielmiessler/LifeOS#2533 ·
Maintainers usually reply within 9 days
-
auto:producer auto:uiux
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
fritzprix/libr-agent#2447 ·
Maintainers usually reply within 1 day