[DRAFT] MAINT Separate server launch, readiness, and cleanup state (#2415) - #2445
Draft
Zhenyu Wang (zhenyu-02) wants to merge 1 commit into
Draft
[DRAFT] MAINT Separate server launch, readiness, and cleanup state (#2415)#2445Zhenyu Wang (zhenyu-02) wants to merge 1 commit into
Zhenyu Wang (zhenyu-02) wants to merge 1 commit into
Conversation
Zhenyu Wang (zhenyu-02)
force-pushed
the
codex/pyrit-2415
branch
from
August 21, 2026 02:48
ae2213a to
7494dbc
Compare
Author
|
@microsoft-github-policy-service agree |
Contributor
|
Is this meant to be a draft PR or ready for review? Zhenyu Wang (@zhenyu-02) |
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
Closes #2415.
This refactors
ServerLauncher.start_asyncinto three internal seams while preserving it as the public orchestrator:stop().The process-group, detached-launch, PID-record, log, and public return/exception behavior remain unchanged. Focused tests cover platform-specific planning, invalid timeouts, cancellation during spawn/PID persistence/health polling/cleanup, repeated cancellation, readiness success, crash diagnostics, timeout cleanup, and cleanup failure retention.
Tests and Documentation
pytest -q tests/unit/cli/test_server_launcher.py— 67 passed, 1 skippedpytest -q tests/unit/cli— 430 passed, 1 skippedruff check pyrit/cli/_server_launcher.py tests/unit/cli/test_server_launcher.pyruff format --check pyrit/cli/_server_launcher.py tests/unit/cli/test_server_launcher.pyty check pyrit/cli/_server_launcher.py tests/unit/cli/test_server_launcher.pypython -m compileall -q pyrit/cli/_server_launcher.py tests/unit/cli/test_server_launcher.pygit diff --checkNo public API or documentation behavior changed. JupyText: N/A.