Repository navigation
fix(session-lock): resolve harness identity when ps is denied (port of #7609) - #7845
Closed
kunchenguid wants to merge 1 commit into
Closed
kunchenguid wants to merge 1 commit into
kunchenguid wants to merge 1 commit into
Conversation
…#7609) Last-resort port of #7609 by @kesslerio, resolved against main after #7746. Adds a ps-free process identity provider (/proc on Linux, bin/fm-procinfo.py on macOS) used only when ps cannot execute, routes session-lock reclaim through fm_session_lock_pid_blocks_reclaim so a live owner whose identity cannot be read blocks reclaim, keeps tagged win:<pid> owners on the fm_win_untag_pid/fm_win_command verdict, and adds coverage in tests/fm-session-lock-ps-denied.test.sh and tests/fm-session-lock-ancestry.test.sh. Conflict resolution: docs/watcher-continuity.md takes #7609's session-lock reclaim bullet and keeps #7746's wording elsewhere. Co-authored-by: kesslerio <2647990+kesslerio@users.noreply.github.com>
Owner
Author
|
Speaking as Kun's firstmate: closing this port for now. CI showed the remaining failures come from #7609's current head, not the conflict resolution, so the work continues on #7609 with @kesslerio (details there). We'll re-port or resolve the conflict ourselves once #7609's head is green. |
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.
Last-resort port of #7609
Speaking as Kun's firstmate: this carries @kesslerio's change from #7609 ("fix(session-lock): resolve harness identity when ps is denied"), resolved against main after #7746 (
7da4c362). All credit for the change goes to @kesslerio, who is credited as co-author on the commit. We opened this port only because #7609 conflicts with main and the merge can't be pushed to the contributor's fork from our side.What it carries (unchanged from #7609 head
a4479244):/procon Linux,bin/fm-procinfo.pyon macOS), used only whenpscannot execute, failing closed with one diagnostic.bin/fm-lock.sh,bin/fm-claude-stop-autoarm.shandbin/fm-turnend-guard-cursor.shgoes throughfm_session_lock_pid_blocks_reclaim, so a live owner whose identity can't be read blocks reclaim, and taggedwin:<pid>owners still reach thefm_win_untag_pid/fm_win_commandverdict.tests/fm-session-lock-ps-denied.test.sh(new) and additions totests/fm-session-lock-ancestry.test.sh.Conflict resolution: the only conflict was the session-lock bullet in
docs/watcher-continuity.md. It takes #7609's reclaim-rule bullet and keeps #7746's "unusable lock" wording on the next bullet. Every other file's change is byte-identical to #7609's diff. No.github/files are touched.Local checks on this commit:
tests/fm-session-lock-ps-denied.test.shALL PASS (macOS-only cases skipped),tests/fm-session-lock-windows-consumers.test.shpasses,bin/fm-lint.shpasses.tests/fm-session-lock-ancestry.test.shpasses every session-lock case and stops at the pty-host reparenting case, the same environment-only stop #7609's body reports.Related: #5238 (the original report).