fix(ci): report runtime shutdown failure diagnostics - #2016
Merged
Merged
Conversation
Signed-off-by: Joshua J. Bouw <jjb@unicity-labs.com>
5 tasks done
Contributor
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
The tests do not yet enforce the required PID and elapsed-time diagnostics.
Review effort: Balanced
Findings: 1
Open (1)
What changed in this PR
Adds actionable daemon shutdown diagnostics to the runtime E2E harness.
Changes:
- Reports PID, elapsed time, exit status, and force-kill usage.
- Adds stubbed shutdown tests and integrates them into CI contracts.
- Preserves existing cleanup and failure behavior.
| File | Description |
|---|---|
scripts/e2e/runtime-process-helpers.sh |
Emits shutdown failure diagnostics. |
scripts/test_runtime_shutdown_diagnostics.py |
Tests shutdown outcomes and reporting. |
scripts/ci/test-release-contracts.sh |
Runs the new regression tests. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Signed-off-by: Joshua J. Bouw <jjb@unicity-labs.com>
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.

Linked Issue
Closes #2015.
Summary
Report why the runtime harness fails while stopping its daemon. This does not fix or waive the shutdown failure observed in #2012.
Changes
Verification
Before the change, two of the three unchanged tests failed because failure diagnostics were empty. After the change all three pass. Bash syntax, ShellCheck and git diff --check pass. These tests prove the reporting contract, not the root cause of the real daemon failure. The full scripts/ci/test-release-contracts.sh suite also passes. Independent review accepted c4b7699 and reproduced the parent/head failure-reporting difference. Follow-up 3d01e42 addresses Copilot's test-coverage finding: both failure branches now require the correct PID, numeric elapsed seconds, exit status and force-kill flag, and clean exit requires empty stderr. All three focused tests pass on the follow-up. Required CI is pending on the new head.
Test Plan
Run python3 scripts/test_runtime_shutdown_diagnostics.py and shellcheck scripts/e2e/runtime-process-helpers.sh. On a future failing real harness run, use the emitted exit status and force-kill field to distinguish early daemon failure from a hung process.
AI / Tool Assistance
Assisted-by: Codex
AI assistance implemented the diagnostics and tests. The complete diff was reviewed and the executable regression was run before and after the change.
Checklist