anomalyco / anomalyco/opencode
tui: /undo fails with Session is busy during generation
Open
@kommander is already working on this.
Since Jul 23, 2026.
- Dominant language
- TypeScript
- Stars
- 209k
- Forks
- 27.5k
- Avg merge
- 7h 2m
- Merged PRs (30d)
- 384
Description
Summary
Running /undo while a response is generating fails with Session is busy. /undo should cancel the active generation and undo the previous message, as it did before the beta.
Environment
- opencode version: 1.18.4
- OS: Darwin 24.5.0 arm64 (macOS)
- Terminal: tmux (
TERM_PROGRAM=tmux,TERM=xterm-256color,COLORTERM=truecolor) - Shell:
/bin/zsh - Install/channel: Homebrew release; user reports this worked before the beta
- Active plugins:
~/.config/opencode/plugins/opencode-anthropic-auth/index.mjs
Reproduction
- Start an agent response.
- While the response is still generating, run
/undo. - Observe the busy-session error.
Expected Behavior
/undo cancels the active generation, then undoes the previous message.
Actual Behavior
/undo fails consistently across sessions with:
Session is busy: ses_<redacted>
It works only after the agent is no longer in progress.
Additional Context
- Reproduces every time across all tested sessions.
- This behavior reportedly worked before the beta.
- Related closed report: #14014 described revert behavior while busy and noted that
session.undoalready aborted ongoing work.
Contributor guide
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.
Assessment
This issue has not been assessed yet.