fix(coding-agent): skip context-incompatible fallbacks - #1338
Conversation
Ultraworked with [omo](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: sisyphus-dev-ai <sisyphus-dev-ai@users.noreply.github.com>
Ultraworked with [omo](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: sisyphus-dev-ai <sisyphus-dev-ai@users.noreply.github.com>
Ultraworked with [omo](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: sisyphus-dev-ai <sisyphus-dev-ai@users.noreply.github.com>
Includes final retry-observer liveness hardening required after review. Ultraworked with [omo](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: sisyphus-dev-ai <sisyphus-dev-ai@users.noreply.github.com>
Ultraworked with [omo](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: sisyphus-dev-ai <sisyphus-dev-ai@users.noreply.github.com>
Ultraworked with [omo](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: sisyphus-dev-ai <sisyphus-dev-ai@users.noreply.github.com>
Ultraworked with [omo](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: sisyphus-dev-ai <sisyphus-dev-ai@users.noreply.github.com>
Ultraworked with [omo](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: sisyphus-dev-ai <sisyphus-dev-ai@users.noreply.github.com>
|
@code-yeongyu This is ready to merge. All repository checks are green; independent code and security reviews both passed; |
Ultraworked with [omo](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: sisyphus-dev-ai <sisyphus-dev-ai@users.noreply.github.com>
…ble-fallback # Conflicts: # packages/coding-agent/src/core/changes.md
|
@code-yeongyu Update: this branch now includes current |
Summary
Verification
Evidence
No real provider credentials or paid calls were used.
Summary by cubic
Fixes retry fallback so it skips context-incompatible model rungs and only settles when no remaining rung can hold the live conversation. Automatic fallback model switches are now transactional — a rejected switch leaves no persisted model change or stale prompt/tool state, and a failed fallback settles the retry lifecycle instead of wedging
prompt().What changed
model_selectbudget check passes; on rejection, session state is restored and nothing is persisted. Persistence is the commit boundary —SessionManagerpersists before exposing an in-memory entry, initial session files are written atomically, and failed appends truncate back.prompt().retry_fallback_exhaustedextension event exposes diagnostics (sessionId,chainKey,from,lastError,exhaustionReason,rejectedCandidates) so an extension can route work to a fresh context; it is notification-only, never blocks retry settlement, and its payload truncates each string field and candidate error to stay under 64 KiB of serialized UTF-8.Written for commit d3dab96. Summary will update on new commits.