Skip to content

refactor: group PTY bindings and lifecycle suites - #33566

Merged
nwparker merged 2 commits into
mainfrom
nwparker/refactor-pty-ownership-current-main
Oct 25, 2026
Merged

nwparker merged 2 commits into
mainfrom
nwparker/refactor-pty-ownership-current-main

Conversation

@nwparker

@nwparker nwparker commented Oct 25, 2026 •

Copy link
Copy Markdown
Contributor

Group PTY host bindings, IPC listener accessors, management and spawn timing, along with 53 test/support files, under src/main/ipc/pty/. Update callers and test-routing, timing and reliability paths to concrete owners. Extract the window-launch case table to keep the parity suite within its existing lint limit, and link historical reliability commands to their renamed commands through currentCommand. No barrel exports or old-path shims.

Validation: two independent source audits and the refactor merge audit passed. Local validation passed 932 cases across 82 whole test files; a focused follow-up against newer main passed 191 cases across 10 files, node typechecking, the Electron build and the normal flaky-test check. Changed-code quality, formatting and affected repository checks passed. All GitHub checks completed successfully or were skipped, including the required aggregate gate.

@coderabbitai

coderabbitai Bot commented Oct 25, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

No actionable comments were generated in the recent review.

Recent 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: 8c82e8e9-f78e-41b0-817f-134853a6b207
Commits

Reviewing files that changed from the base of the PR and between 6c9c7b0 and ffbe592.

Files selected for processing: 96
  • config/flaky-test-pattern-baseline.txt
  • config/reliability-gates.jsonc
  • config/scripts/ci-shard-timings.json
  • config/scripts/pr-package-test-paths.mjs
  • src/main/ipc/pty-closed-pane-spawn-refusal.test.ts
  • src/main/ipc/pty-ipc-suite-environment.ts
  • src/main/ipc/pty-ipc-test-harness.ts
  • src/main/ipc/pty-ipc-test-surface.ts
  • src/main/ipc/pty-restored-appimage-cli-shim-refresh.test.ts
  • src/main/ipc/pty-runtime-ssh-binding-persistence.test.ts
  • src/main/ipc/pty-spawn-pi-owner-env.test.ts
  • src/main/ipc/pty/daemon-late-exit-test-fixture.ts
  • src/main/ipc/pty/delivery/debug.ts
  • src/main/ipc/pty/ipc/claude-diff-panel-notice.test.ts
  • src/main/ipc/pty/ipc/claude-diff-panel-notice.ts
  • src/main/ipc/pty/ipc/claude-old-terminal.test.ts
  • src/main/ipc/pty/ipc/claude-old-terminal.ts
  • src/main/ipc/pty/ipc/codex-shared-server.test.ts
  • src/main/ipc/pty/ipc/codex-shared-server.ts
  • src/main/ipc/pty/ipc/inspect.ts
  • src/main/ipc/pty/ipc/leaf-move.ts
  • src/main/ipc/pty/ipc/newer-daemon-hold.ts
  • src/main/ipc/pty/ipc/renderer-kill.ts
  • src/main/ipc/pty/ipc/resize-visibility.ts
  • src/main/ipc/pty/ipc/serialize-buffer.ts
  • src/main/ipc/pty/ipc/session-listing.ts
  • src/main/ipc/pty/ipc/snapshot.ts
  • src/main/ipc/pty/ipc/spawn-begin.ts
  • src/main/ipc/pty/ipc/spawn-state.ts
  • src/main/ipc/pty/ipc/spawn.ts
  • src/main/ipc/pty/ipc/terminal-view-attributes-ipc.ts
  • src/main/ipc/pty/ipc/write.ts
  • src/main/ipc/pty/pty-absent-pane-respawn.test.ts
  • src/main/ipc/pty/pty-activation-inventory-scope.test.ts
  • src/main/ipc/pty/pty-agent-launch-pane-attach.test.ts
  • src/main/ipc/pty/pty-agent-pane-launch.test.ts
  • src/main/ipc/pty/pty-closed-pane-spawn-refusal.test.ts
  • src/main/ipc/pty/pty-codex-account-attribution.test.ts
  • src/main/ipc/pty/pty-controller-ownership-routing.test.ts
  • src/main/ipc/pty/pty-controller-process-inventory.test.ts
  • src/main/ipc/pty/pty-controller-spawn-admission.test.ts
  • src/main/ipc/pty/pty-daemon-controller-teardown.test.ts
  • src/main/ipc/pty/pty-daemon-spawn-agent-home-env.test.ts
  • src/main/ipc/pty/pty-daemon-spawn-codex-auth.test.ts
  • src/main/ipc/pty/pty-daemon-spawn-session-identity.test.ts
  • src/main/ipc/pty/pty-daemon-spawn-wsl-runtime.test.ts
  • src/main/ipc/pty/pty-dead-owner-respawn.test.ts
  • src/main/ipc/pty/pty-dispatcher-handshake-osc-answers.test.ts
  • src/main/ipc/pty/pty-hidden-at-spawn-mark.test.ts
  • src/main/ipc/pty/pty-host-bindings.ts
  • src/main/ipc/pty/pty-ipc-hidden-restore-ack.test.ts
  • src/main/ipc/pty/pty-ipc-listener-accessors.ts
  • src/main/ipc/pty/pty-launch-parity-window.test-cases.ts
  • src/main/ipc/pty/pty-launch-parity.test.ts
  • src/main/ipc/pty/pty-launch-race-parity.test.ts
  • src/main/ipc/pty/pty-listener-teardown-and-orphans.test.ts
  • src/main/ipc/pty/pty-login-shell-startup-commands.test.ts
  • src/main/ipc/pty/pty-management-async-io-health.test.ts
  • src/main/ipc/pty/pty-management.test.ts
  • src/main/ipc/pty/pty-management.ts
  • src/main/ipc/pty/pty-pane-claim-arbitration.test.ts
  • src/main/ipc/pty/pty-pane-materialization-race.test.ts
  • src/main/ipc/pty/pty-pane-reservation-settlement.test.ts
  • src/main/ipc/pty/pty-pane-restart-replace.test.ts
  • src/main/ipc/pty/pty-persisted-incarnation-repair.test.ts
  • src/main/ipc/pty/pty-renderer-liveness-guard.test.ts
  • src/main/ipc/pty/pty-restore-record-seeding.test.ts
  • src/main/ipc/pty/pty-restored-appimage-cli-shim-refresh.test.ts
  • src/main/ipc/pty/pty-runtime-hidden-at-spawn-mark.test.ts
  • src/main/ipc/pty/pty-runtime-kill-and-exit.test.ts
  • src/main/ipc/pty/pty-runtime-ssh-binding-persistence.test.ts
  • src/main/ipc/pty/pty-serializer-settlement-mapping.test.ts
  • src/main/ipc/pty/pty-session-liveness-and-ownership.test.ts
  • src/main/ipc/pty/pty-spawn-codex-home-unavailable.test.ts
  • src/main/ipc/pty/pty-spawn-cwd-fallback-hung-folder.test.ts
  • src/main/ipc/pty/pty-spawn-cwd-fallback.test.ts
  • src/main/ipc/pty/pty-spawn-env-agent-overlays.test.ts
  • src/main/ipc/pty/pty-spawn-env-codex-home-routing.test.ts
  • src/main/ipc/pty/pty-spawn-env-codex-resume-provenance.test.ts
  • src/main/ipc/pty/pty-spawn-env-terminal-basics.test.ts
  • src/main/ipc/pty/pty-spawn-pi-owner-env.test.ts
  • src/main/ipc/pty/pty-spawn-placement-threading.test.ts
  • src/main/ipc/pty/pty-spawn-runtime-handle-binding.test.ts
  • src/main/ipc/pty/pty-spawn-timing.test.ts
  • src/main/ipc/pty/pty-spawn-timing.ts
  • src/main/ipc/pty/pty-ssh-stop-verdict.test.ts
  • src/main/ipc/pty/pty-startup-barrier-and-listing.test.ts
  • src/main/ipc/pty/pty-startup-swap-window-presence.test.ts
  • src/main/ipc/pty/pty-windows-shell-selection.test.ts
  • src/main/ipc/pty/pty-write-ipc-validation.test.ts
  • src/main/ipc/pty/register-handlers.ts
  • src/main/ipc/pty/spawn-commit-assembly.ts
  • src/main/startup/browser-process-user-agent-ordering.test.ts
  • src/main/startup/main-process-preflight.ts
  • src/main/window/attach-main-window-services.test.ts
  • src/main/window/attach-main-window-services.ts
Files with no reviewable changes: 4
  • src/main/ipc/pty-closed-pane-spawn-refusal.test.ts
  • src/main/ipc/pty-restored-appimage-cli-shim-refresh.test.ts
  • src/main/ipc/pty-spawn-pi-owner-env.test.ts
  • src/main/ipc/pty-runtime-ssh-binding-persistence.test.ts

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 7 remain after this review.

Walkthrough

PTY IPC modules and tests were reorganized under a nested directory, and affected imports and mocks were updated. CI timing entries now use the nested test paths. Four regression test suites were added at the new location, and launch-parity window cases were extracted into a shared fixture. The summaries show no changes to production runtime behavior.

Priority: Pending latest changes

Merge Risk: Minimal · up to ffbe5

No actionable issue is identified in the PTY reorganization. Merge after the required checks pass.

Pre-merge checks: Passed 3 · Failed 1 · Inconclusive 1

Failed Failed checks: 1 warning · 1 inconclusive

Check name Status Explanation Resolution
Description check Warning The description summarizes the refactor and validation, but it omits most required template sections, including ELI5, Why, Linked Issue, Visual Proof, Testing checklist, AI Disclosure, Review, Notes, … Update the PR description to use the required headings. Add a plain-language summary, user-facing changes, rationale, an actual linked issue, N/A with a reason for Visual Proof if applicable, testing steps and platform coverage, AI disclo…
Docstring Coverage Inconclusive Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 3 functions across 50 files. (40 skipped: … Write docstrings for the functions missing them to satisfy the coverage threshold.
Passed Passed checks: 3 passed
Check name Status Explanation
Title check Passed The title is concise, specific, and accurately summarizes the PTY grouping refactor.
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.
Full details: Description check

Explanation

The description summarizes the refactor and validation, but it omits most required template sections, including ELI5, Why, Linked Issue, Visual Proof, Testing checklist, AI Disclosure, Review, Notes, and Checklist.

Resolution

Update the PR description to use the required headings. Add a plain-language summary, user-facing changes, rationale, an actual linked issue, N/A with a reason for Visual Proof if applicable, testing steps and platform coverage, AI disclosure when applicable, review notes, boundary status, compatibility notes, and completed checklist items.

Full details: Docstring Coverage

Explanation

Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 3 functions across 50 files. (40 skipped: 2 unsupported, 38 over the file limit.)

Resolution

Write docstrings for the functions missing them to satisfy the coverage threshold.

Finishing Touches: 💡 2
📝 Generate docstrings: 💡
  • Commit to this branch
  • Create a new PR
🛠️ Fix failing CI checks: 💡
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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.

@nwparker
nwparker merged commit 838134f into main Oct 25, 2026
50 checks passed
tomarai85 added a commit to tomarai85/orca that referenced this pull request Oct 26, 2026
Point the imports of persistence-test-harness, persistence-session-fixtures
and pty-host-bindings at the paths main moved them to (stablyai#33233, stablyai#33566), and
say above each 420 s timeout why the relaunch journey needs it, as main's
test-timeout-needs-reason rule (stablyai#33430) asks.
tomarai85 added a commit to tomarai85/orca that referenced this pull request Oct 26, 2026
Point the imports of persistence-test-harness, persistence-session-fixtures
and pty-host-bindings at the paths main moved them to (stablyai#33233, stablyai#33566), and
say above each 420 s timeout why the relaunch journey needs it, as main's
test-timeout-needs-reason rule (stablyai#33430) asks.
tomarai85 added a commit to tomarai85/orca that referenced this pull request Oct 26, 2026
Point the imports of persistence-test-harness, persistence-session-fixtures
and pty-host-bindings at the paths main moved them to (stablyai#33233, stablyai#33566).
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