Skip to content

fix(wework): preserve sidebar running state after reload - #2605

Merged
qdaxb merged 1 commit into
mainfrom
fix/wework-sidebar-running-state
Aug 12, 2026
Merged

fix(wework): preserve sidebar running state after reload#2605
qdaxb merged 1 commit into
mainfrom
fix/wework-sidebar-running-state

Conversation

@qdaxb

@qdaxb qdaxb commented Aug 12, 2026

Copy link
Copy Markdown
Contributor

Summary

  • keep a concrete streaming transcript turn authoritative when the coarse transcript running flag is stale
  • restore the task lifecycle so the sidebar spinner and composer controls remain consistent after reload
  • extend the CI-covered desktop goal-lifecycle checkpoint with a stale-transcript regression assertion

Verification

  • pnpm --filter wework test src/features/workbench/runtimeTaskLifecycle/RuntimeTaskLifecycleStore.test.ts src/components/layout/DesktopSidebar.test.tsx
  • pnpm --dir wework exec prettier --check ...
  • focused ESLint on changed TypeScript files
  • pnpm --filter wework typecheck
  • pre-push Wework ESLint, TypeScript, and unit-test suite

Local desktop E2E note

The local goal-lifecycle attempts were interrupted in shared bootstrap checkpoints before reaching this scenario while another worktree was concurrently running a real Tauri desktop E2E instance. The regression is attached to the existing CI-covered checkpoint so GitHub Actions validates it in an isolated environment.

Summary by CodeRabbit

  • Bug Fixes
    • Improved recovery of active tasks after a reload, including cases where transcript status is stale or reports that execution has stopped.
    • Preserved streaming, busy, and running indicators while an active task continues.
    • Kept recovered tasks visible in the running tasks sidebar.

@coderabbitai

coderabbitai Bot commented Aug 12, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: f3905ea4-704d-481d-8a6f-4ad50564aedf

📥 Commits

Reviewing files that changed from the base of the PR and between 5b9f3d5 and d38d8a1.

📒 Files selected for processing (4)
  • wework/e2e/desktop/modules/goal-flows.mjs
  • wework/src/features/workbench/runtimeTaskLifecycle/RuntimeTaskLifecycleProvider.tsx
  • wework/src/features/workbench/runtimeTaskLifecycle/RuntimeTaskLifecycleStore.test.ts
  • wework/src/features/workbench/runtimeTaskLifecycle/RuntimeTaskLifecycleStore.ts

📝 Walkthrough

Walkthrough

The runtime lifecycle now synchronizes received transcripts and restores streaming turns even when the transcript reports running: false. Unit and end-to-end tests verify active execution, streaming, busy state, and sidebar visibility after reload.

Changes

Runtime transcript recovery

Layer / File(s) Summary
Transcript synchronization and turn recovery
wework/src/features/workbench/runtimeTaskLifecycle/RuntimeTaskLifecycleProvider.tsx, wework/src/features/workbench/runtimeTaskLifecycle/RuntimeTaskLifecycleStore.ts
transcript_received events now pass transcripts to the store. Streaming turns recover before the coarse transcript running state is evaluated.
Recovery regression coverage
wework/src/features/workbench/runtimeTaskLifecycle/RuntimeTaskLifecycleStore.test.ts, wework/e2e/desktop/modules/goal-flows.mjs
Tests verify that stale running: false data preserves execution, streaming, busy state, running-task keys, and sidebar visibility.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Possibly related PRs

Suggested labels: ci:all

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the primary change: preserving the sidebar running state after reload.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/wework-sidebar-running-state

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@qdaxb
qdaxb added this pull request to the merge queue Aug 12, 2026
Merged via the queue into main with commit 09aa68b Aug 12, 2026
50 checks passed
@qdaxb
qdaxb deleted the fix/wework-sidebar-running-state branch August 12, 2026 05:51
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