Skip to content

fix(opencode): preserve the session model on resume - #8

Merged
devswha merged 1 commit into
mainfrom
codex/fix-opencode-resume-model
Jul 22, 2026
Merged

fix(opencode): preserve the session model on resume#8
devswha merged 1 commit into
mainfrom
codex/fix-opencode-resume-model

Conversation

@devswha

@devswha devswha commented Jul 22, 2026

Copy link
Copy Markdown
Owner

Summary

  • prefer an explicit ChatMux model change, then the provider session's actual model, when resuming
  • preserve OpenCode's providerID/id model identifier from its session database
  • add regression coverage for both precedence and OpenCode model parsing

Root cause

The native OpenCode session used openai/gpt-5.5, but ChatMux resumed it with the new-session UI default anthropic/claude-sonnet-4-5. OpenCode stores the model as { providerID, id }; ChatMux also discarded providerID, so it could not reconstruct the CLI model argument correctly.

Verification

  • targeted provider/OpenCode tests (15/15)
  • npm run typecheck
  • npm run lint
  • npm run build

@devswha

devswha commented Jul 22, 2026

Copy link
Copy Markdown
Owner Author

E2E QA evidence (2026-07-22): after restoring the stored OpenCode model through this fix, the actual browser history-resume turn completed with CHATMUX_E2E_OPENCODE_T2 value=OPENCODE_T1.

@devswha
devswha merged commit 4c6c69f into main Jul 22, 2026
1 of 2 checks passed
@devswha
devswha deleted the codex/fix-opencode-resume-model branch August 13, 2026 13:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant