Repository navigation
A Pi or OMP helper session no longer takes over its lead's terminal pane - #32261
brennanb2025 wants to merge 23 commits into
Conversation
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
No actionable comments were generated in the recent review. ℹ️ Recent review info
Walkthrough
Priority: Merge Risk:
|
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
- Source mode: Auto
- Repository: Unavailable
- Branch: Unavailable
- File: No configuration file from this repository applied
- Commit: Unavailable
- Layers: Repository UI
- Review profile: CHILL
- Plan: Advanced
- Run ID:
dda8119e-94b3-43d5-a1f4-4481fff21cb7
📒 Files selected for processing: 11
src/main/pi/agent-status-declared-session.test.tssrc/main/pi/agent-status-extension-omp-lifecycle.test.tssrc/main/pi/agent-status-extension-source.tssrc/main/pi/agent-status-extension-test-harness.tssrc/main/pi/agent-status-handler-source.tssrc/main/pi/agent-status-post-queue-source.tssrc/main/pi/agent-status-session-boundary-source.tssrc/main/pi/agent-status-subagent-roster-source.tssrc/main/pi/agent-status-ui-prompt-source.tssrc/main/pi/omp-model-command-source.tssrc/main/pi/omp-session-status-owner-source.ts
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 2 remain after this review.
There was a problem hiding this comment.
Actionable comments posted: 2
ℹ️ Review info
⚙️ Run configuration
- Source mode: Auto
- Repository: Unavailable
- Branch: Unavailable
- File: No configuration file from this repository applied
- Commit: Unavailable
- Layers: Repository UI
- Review profile: CHILL
- Plan: Advanced
- Run ID:
b2a17592-8551-4a09-b4b2-11abf47aec6a
📒 Files selected for processing: 12
src/main/pi/agent-status-completion-delivery.test.tssrc/main/pi/agent-status-declared-session.test.tssrc/main/pi/agent-status-extension-async-subagents.test.tssrc/main/pi/agent-status-extension-omp-lifecycle.test.tssrc/main/pi/agent-status-extension-omp-model.test.tssrc/main/pi/agent-status-extension-session-change.test.tssrc/main/pi/agent-status-extension-source.test.tssrc/main/pi/agent-status-extension-source.tssrc/main/pi/agent-status-handler-source.tssrc/main/pi/agent-status-ui-prompt-source.tssrc/main/pi/omp-session-status-owner-source.tssrc/main/pi/omp-session-status-owner.test.ts
💤 Files with no reviewable changes: 1
- src/main/pi/agent-status-handler-source.ts
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 4 remain after this review.
|
A helper inside a Pi or OMP process could replace the lead terminal's title and saved resume identity. The lead appeared gone, and an Orca restart resumed the helper. This PR selects one lead for status/title, defers shared setup until selection, and retires status and title registrations independently. Explicit new/resume/fork/reload and former-helper selection remain supported; History stays flat and earlier rebound entries are not repaired. The 10-24 tripwire panel chose the simpler common pattern. Independent helper attention delivery, request maps, liveness probing and receiver snapshots are removed. Lead-native Pi modal waiting, OMP answers and parent-side child progress remain. The same selector now rejects a later SDK-default-main OMP18 startup over an existing lead; explicit switches still select it. Restoring the existing Pi receiver also fixes blank Done after unsaved /new. No second ownership guard, saved field, wire operation or command wrapper was added. Intended limits remain: an unmarked helper created before the lead may win first-start selection, and an already-running old CLI can retain legacy behavior until restart. The original three review rounds and first main sync are retained. The final one-round tripwire panel and one independent delta review completed on c425a5e, with no proved new finding; the whole reference comparison is complete. Both reported regressions fail against the previous production head and pass after the fix. The reviewer independently ran both risk files. Targeted final test executions total 282 passes across18 named files; they are a union, not a single full-suite run. Attention-only assertions were removed while preserving the real two-SessionManager/real-Pi-argv, lifecycle, delivery and cross-version contracts. Source plus all support is 440/560 changed lines:289 production,102 harness/context,43 runtime smoke,6 workflow. Test deletion gives no budget credit. Normal hook passed. Current-head CI completed 26 successful,16 skipped checks, including typechecking, Windows packaging and Pi runtime contracts on Windows/macOS/Ubuntu; GitHub reported CLEAN/out of draft. Targeted real macOS Pi1.3 + helper0.22 and OMP18.12.6 delta QA completed on this head. The genuine prior fd saved profile was upgraded and continued with real replies. Actual Pi helper late result kept lead ID/path/title/status/persisted resume and History target; native lead modal stayed waiting after actual completion, then Yes returned true and settled. Unsaved /new had no file and retained the prior nonblank row; materialization and persisted /resume followed the right session. Plain pi returned a real reply. Actual OMP SDK construction omitted depth/prefix and declared main after the lead; its real result did not rebind the lead. Explicit former-helper resume then selected that transcript, produced a new reply and matched the History Jump target. Native files, rendered pixels and persisted projections were checked separately; driver exit0 alone is not the verdict. The Pi helper used model-supplied max_turns1 and displayed steered/turn-limit wording; the requested real result arrived late. This is not an unlimited-helper or survival-across-/new claim. The OMP invocation frame is not a separately prolonged working interval; native startup/result records cover the default-main case. Prior unchanged alias/fork/reload/restart/OMP17/Prime/Windows evidence carries, with its existing qualifications. Windows delta not executed: no Windows-specific code change; requested host unreachable and needs a person. No new-head Windows pass or waiver is claimed. Unchanged phone consumers use tests; no shared Claude/Codex identity path changed. Historical qualifications remain: the original released Pi frozen pane lacked resume authority before this delta and released control also restored a shell; the earlier removal write is unknown. Original OMP17 no-anchor recovery failed before a different natural-anchor recovery passed. Initial Pi/OMP18 live-status gaps traced to unchanged resume/OSC projection despite full persisted/hydrated rows and intact conversations. Original provider/rig failures, stock-tool failures and the unexecuted disposed-lead/independent-helper-survivor variant remain qualified. Independent SDK successes do not pass stock-tool failures. No new PR-specific defect was established and no repair/waiver was invented. Cleanup: graceful Browser.close,34 exact process identities checked,0 owned survivors,0 admitted-port listeners; ticket2257 released. Nine real-config hashes unchanged; .codex/auth.json changed, cause unestablished, hash-only observation recorded. No credential contents read/copied/edited. For Brennan's review — current-head whole-window evidence: Carried baseline / unchanged-flow proof (earlier head; precise limits above)Judgment spots: single lifecycle selection, deferred adoption and cleanup, real-manager startup regression. After main advanced, merge conflicts blocked this PR. Merge 56781d9 brings in main 870038c. The single Pi turn-start conflict retains this PR’s modal/turn state resets and main’s reply-timestamp reset. The required merge lint-staged check passed, and an independent narrow merge review found no broken flow. CI on the merge head completed: 42 checks (26 successful, 16 skipped), including the aggregate PR gate, Windows packaging, all Node test shards and Pi runtime on Windows/macOS/Ubuntu. Existing real-run evidence remains on c425a5e; no additional QA was needed for this main merge, and all earlier qualifications remain. Main’s repository-wide comment cleanup later introduced conflicts. Merge 9bd99a5 brings in main 7d18e19. Ten Pi conflicts preserve this PR’s executable behavior and regression assertions while retaining the comment cleanup. The required merge lint-staged check passed; independent narrow review verified both parents and found no broken flow. The first merged-head CI run passed TypeScript compilation and all three Pi runtime platforms, but a newly introduced main ratchet rejected the unchanged test fixture’s wall-clock timestamp. Test-only commit 409481d replaces it with a fixed timestamp; its normal hook passed. CI on corrected head 409481d completed: 42 checks (26 successful, 16 skipped), including the aggregate gate, all Node test shards, Windows packaging, WSL and Pi runtime on Windows/macOS/Ubuntu. GitHub reports CLEAN/MERGEABLE. Existing QA evidence stays on c425a5e, with the same qualifications; this merge required no QA rerun. After main advanced again, merge a3cd89f brings in main 843e502. The three conflicts preserve the OMP helper-takeover and Pi unsaved |
|
Superseded by #33595 (merged, co-authored by you), which fixes the Pi helper takeover (status, resume, title) with a smaller change. OMP was left as on main: the installed OMP 18 doesn't expose role declarations to extensions and main's OMP gate already rejects other sessions. Reopen if OMP needs the broader handling. |












A Pi or OMP helper could replace its lead's terminal tab identity, title and Session History resume target. The lead conversation appeared gone, and an Orca restart resumed the helper. Status and title registrations inside one CLI process shared ownership and delivery state.
The selected lead now keeps its pane, title and saved resume target when a helper starts or finishes. Explicit new, resume, fork and reload remain supported, including selecting a former helper and fileless Pi successors. History stays flat, the saved format stays the same, and previously rebound entries are not repaired. Tracked in STA-11554.
Status and title consume one process-local session selection and retire independently. Shared delivery and roster state are adopted only after selection. OMP18 role declarations reject declared sub starts; a later SDK helper declared main cannot replace an already selected lead on startup. Explicit switch/branch can select another session. Pi1.3 and OMP17 use the first eligible start and explicit provider lifecycle transitions; Pi replacements follow predecessor and announced-shutdown facts. Model commands and native answers remain provider actions.
The 10-24 tripwire panel selected the simpler common pattern. The helper-attention registry, retained request bodies, context liveness probes, replay and receiver snapshot protocol are removed. Separate helper reporting cannot take over the pane. Lead-local Pi modal waiting, native questions, OMP approvals and plan answers, and parent-side subagent progress/completion holds remain. The Pi receiver and question recognizer return to main's existing behavior. In particular, unsaved Pi /new no longer turns a startup metadata event into a blank Done row.
Intended limits: a helper created by another extension before the lead starts can win the first-start fallback; a CLI already running during an Orca upgrade can retain its old reporting behavior until CLI restart. No new saved field, wire operation, capability, minimum version, command wrapper or user-facing control is added. Independently supplied SDK UI is possible, but no existing actionable same-pane helper flow requiring a separate relay was established. The stock Pi helper binds no UI; its existing roster-event mismatch is outside scope. No independent helper-request persistence, answer router or History grouping is promised.
Validation on c425a5e: both reported regressions fail against the prior head and pass after the fix. The tests use authentic OMP18 default-main context facts for status/title selection, and real pinned Pi1.3 SessionManagers with actual Pi argv through the generated sender, real normalizer, hook server and visible-row selector for unsaved /new. Persisted /resume remains an identity-only control; no visible resume regression is claimed. Targeted runs cover 282 passing tests across 18 named files. Attention-only tests were removed while retaining the two-manager regression, delivery, transition, native-lead and cross-version contracts. Source plus all harness, smoke and workflow support totals 440 changed lines against the merged main base, below the binding 560 ceiling; test deletions provide no budget credit. The normal hook passed.
The original three review rounds and single main sync are retained. The fresh delta review is complete with no proved new findings and refs=done. Current-head CI is complete: 26 successful and 16 skipped checks, CLEAN and out of draft. Targeted current-head Pi/OMP delta QA is complete on macOS. Real Pi helper late-result, selected-lead modal completion/Yes/close, unsaved /new, persisted /resume, literal pi, actual OMP18 SDK-default-main helper construction after lead selection, explicit former-helper resume/reply and desktop History targets all matched selected and persisted identities. The prior saved fd profile was upgraded into this candidate and yielded real continuation replies. The final existing status comment links the screenshots and precise limits. Earlier Windows/POSIX evidence applies only to unchanged flows. The changed default-main startup and /new behavior is not claimed as exercised on Windows; the requested Windows host is unreachable and needs a person, and this delta contains no Windows-specific code. No second full QA round or main merge is planned.
Historical QA observations remain qualified: the original released Pi pane lacked a valid resume target before this delta, and frozen released control also restored a shell; OMP17's original missing-anchor failure was followed by a successful natural-anchor cold restore. Earlier Pi/OMP18 initial live-status gaps traced to unchanged resume/OSC projection after successful full-row persistence/hydration. Native session content and later real replies were retained. Provider/rig failures and the unexecuted disposal-survivor variant remain recorded. These observations are neither new-head passes nor waivers. Prime status behavior is unchanged; its generated title source consumes the same selector but its executable does not use the OMP declaration branch. Unchanged phone consumers use their tests under the QA table; no shared Claude/Codex identity path changes remain.
QA cleanup: graceful Browser.close, 34 recorded process identities checked, zero owned survivors and zero admitted-port listeners; ticket2257 released. Nine config hashes were unchanged; real .codex/auth.json changed, with cause unestablished and no credential contents read/copied/edited. The hash-only observation is recorded. The stock Pi helper used a model-supplied one-turn limit and returned the requested result late; this is not an unlimited-helper or survival-across-/new claim. Original failed/qualified cells remain qualified.