Skip to content

fix: reliable todo panel updates + close when work stops#511

Merged
alari76 merged 2 commits into
mainfrom
fix/todo-panel-updates
Jun 12, 2026
Merged

fix: reliable todo panel updates + close when work stops#511
alari76 merged 2 commits into
mainfrom
fix/todo-panel-updates

Conversation

@alari76

@alari76 alari76 commented Jun 12, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Server: TaskUpdate with an unknown task id was silently dropped (no todo_update emitted), leaving the chat todo panel stale and unable to ever reach all-done. Causes: taskSeq reset on every TodoWrite and an empty task map after process restarts while the CLI's task list survives the resume. Now: upsert unknown ids, keep ids monotonic across list generations, honor explicit taskId/id on TaskCreate, and seed restarted processes from the last todo_update in session history. Emitted snapshots are copied to avoid aliasing into stored history. Same fixes mirrored in OpenCodeProcess.
  • Frontend: TodoPanel is now turn-aware via an isProcessing prop — auto-dismisses 3s after all tasks complete once the turn ends (10s while still processing), collapses to the compact pill when a turn ends with unfinished tasks (Claude often forgets the final update), and detects replaced task lists by id signature (not just count) so a dismissed panel re-shows for the next list.
  • Adds component tests for TodoPanel show/hide/collapse behavior and updates server task-tool tests.

Test plan

  • npm run build (typecheck + vite) passes
  • npm test — 2170 tests pass, incl. 9 new TodoPanel tests covering turn transitions with fake timers
  • npm run lint — 0 errors, no new warnings in touched files
  • Manual: run a multi-task session, verify panel updates live, collapses on turn end, and dismisses after completion

🤖 Generated with Claude Code

alari76 and others added 2 commits June 12, 2026 11:02
TaskUpdate calls with ids the server didn't know (taskSeq reset on
TodoWrite, empty task map after process restart) were silently dropped,
leaving the chat todo panel stale and preventing it from ever reaching
all-done. Server now upserts unknown ids, keeps task ids monotonic,
honors explicit ids, and seeds restarted processes from the last
todo_update in history.

Frontend panel is now turn-aware: dismisses 3s after completion once
the turn ends (10s while processing), collapses to the pill when a turn
ends with unfinished tasks, and detects replaced lists by id signature
so a dismissed panel re-shows for new task lists.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Codex emits the full plan on every turn/plan/updated notification, so
there is no incremental task state to seed after a restart.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@alari76
alari76 force-pushed the fix/todo-panel-updates branch from 5c3f413 to 3b8b882 Compare June 12, 2026 08:03
@alari76
alari76 merged commit 47da8e1 into main Jun 12, 2026
2 checks passed
@alari76
alari76 deleted the fix/todo-panel-updates branch June 12, 2026 08:05
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