Repository navigation
Conversation
Give every editor-replacing surface a single cancellable owner so selectors, extension inputs, custom editors, and overlays cannot restore stale focus. Preserve exclusive owners through controlled teardown and cover the custom UI regression.
Route plan decisions, authentication dialogs, and share progress through cancellable editor ownership. Preserve accepted continuation handoff state so delayed asynchronous completions cannot reclaim or corrupt the active interface.
- Routing prompts through the runtime pulled the task boundary resolver, harness status indicator, and /profile command into the TUI, none of which resolve against main - Removing them leaves the exclusive prompt ownership that plan continuations depend on, keeping the interactive mode free of task profile modules
- Flushing the compaction queue now submits through the runtime so queued prompts serialize against plan continuations, but the test still asserted on the session double - Asserting on the runtime double keeps the test aligned with the admission path it is meant to pin
Issacboy123
approved these changes
Aug 17, 2026
Issacboy123
left a comment
Contributor
There was a problem hiding this comment.
The editor-ownership and async UI changes give plan decisions a sensible place to live without competing with selectors or extensions. However, in this PR, submitting a plan changes session state without opening a decision UI. #92 fixes that by keeping the pending-plan reconciliation centralized so new prompt paths cannot miss it. I didn't find any other issues in this PR.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Serializes interactive editor UI ownership and routes interactive prompts through the runtime, so an accepted plan can take exclusive ownership of the prompt path without racing other editor UI.
This is the first half of #72, which was 1484 lines and is split here to stay under the review size limit.
Reasoning
Plan decisions mount their own editor UI, and the existing code allowed two owners to mount at once, which left a stale loader behind when a decision was superseded.
Giving editor UI a single owner with explicit handoff makes the plan decision safe to open and cancel at arbitrary lifecycle points.
Prompts now go through
runtimeHost.promptrather thansession.promptso they queue behind an in-flight plan continuation instead of interleaving with it.The compaction flush test is updated to assert on that path for the same reason.
Task routing progress, the
/profilecommand, and harness session labels are removed here rather than carried, since they resolve against the task profile stack.Changes
/profilecommand, and harness session labelsTesting
npx vitest --run test/interactive-mode-compaction.test.ts test/interactive-mode-status.test.tstsgo --noEmitreports zero errors