fix(install): windows-safe liveness probe in runtime_status#1746
Open
ketpatil77 wants to merge 1 commit into
Open
fix(install): windows-safe liveness probe in runtime_status#1746ketpatil77 wants to merge 1 commit into
ketpatil77 wants to merge 1 commit into
Conversation
Contributor
PR governanceThis PR follows the template and is marked ready for human review. |
JerrettDavis
approved these changes
Jul 3, 2026
JerrettDavis
left a comment
Collaborator
There was a problem hiding this comment.
Reviewed the runtime liveness change. The new helper avoids the Windows os.kill(pid, 0) crash path by preferring psutil when available, preserves a POSIX fallback, treats permission as live, and catches the Windows SystemError failure mode. The tests cover the helper and runtime_status wiring. Checks are green; this looks ready.
# Conflicts: # headroom/install/runtime.py # tests/test_install/test_runtime.py
3921915 to
29f5b06
Compare
Author
|
Conflict rebase is done. Branch now sits on current |
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.
Description
Windows-safe liveness probe for
headroom install status.runtime_status()now checks PID liveness through a helper that avoids blindly callingos.kill(pid, 0)on Windows.Closes #1746
Type of Change
Changes Made
headroom/install/runtime.py: added_pid_alive()withpsutil.pid_existsfirst, then a safeos.killfallback that catchesSystemError.headroom/install/runtime.py:runtime_status()now calls_pid_alive()instead of signalling the PID directly.tests/test_install/test_runtime.py: added regression tests for helper behavior and runtime status wiring.Testing
pytest)ruff check .)mypy headroom)Test Output
Real Behavior Proof
runtime_status()no longer crashes on detached Windows PIDs and routes through helper logic instead of directos.kill(pid, 0).Review Readiness
Checklist