Repository navigation
fix(windows): fail closed on unknown PTY identity - #10674
Merged
Merged
Conversation
Contributor
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (5)
🚧 Files skipped from review as they are similar to previous changes (2)
📝 WalkthroughWalkthroughWindows PTY descendant sweeping now requires an 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches📝 Generate docstrings
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. Comment |
Only taskkill when the identity probe returns `own`; skip tree-kill for `unknown`/`foreign`/`absent` to avoid terminating unrelated processes. Clarifies the fail-closed behavior across agent and plain shell teardown paths, matching the POSIX descendant-snapshot discipline.
This was referenced Jul 27, 2026
bbingz
added a commit
to bbingz/orca
that referenced
this pull request
Aug 5, 2026
Drop redundant Windows root-identity plumbing already covered by upstream stablyai#10484/stablyai#10674, document Job Object as the primary reaper with identity-gated taskkill as fallback, guard Apple/OpenBSD spawn helpers to avoid unused-function -Werror noise, and regenerate the node-pty patch so it applies cleanly to 1.1.0.
enrick-dev
pushed a commit
to enrick-dev/orca
that referenced
this pull request
Oct 15, 2026
* fix(windows): fail closed on unknown PTY identity * Gate Windows tree-kill on PTY identity verification Only taskkill when the identity probe returns `own`; skip tree-kill for `unknown`/`foreign`/`absent` to avoid terminating unrelated processes. Clarifies the fail-closed behavior across agent and plain shell teardown paths, matching the POSIX descendant-snapshot discipline.
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
Windows PTY tree teardown now authorizes
taskkill /T /Fonly when the live verifier returns exactlyownand the caller still owns the PTY root.unknown, including unavailable, rejected, timed-out, or ambiguous process probes, fails closed for tree-kill authorization;foreignandabsentalso skip tree-kill. The existingkillRootpath still runs infinally, so root teardown is preserved even when identity evidence is unavailable or taskkill races an exited tree.Tests
pnpm exec vitest run --config config/vitest.config.ts src/main/pty-descendant-termination.test.ts src/main/windows-pty-root-identity.test.ts(56 passed)pnpm exec oxlint --quiet src/main/pty-descendant-termination.ts src/main/pty-descendant-termination.test.ts src/main/windows-pty-root-identity.ts src/main/windows-pty-root-identity.test.tsAccepted residuals
own.Release scan
The local finding is recorded in
/private/tmp/prod-release-worker-reports/platform.md(also summarized in/private/tmp/prod-release-worker-reports/FINAL.md); the internal report is not uploaded. This change addresses the fail-open portion of the finding introduced by #10100 and #10339, following the partial identity guard in #10484.