Read run state directly, delegate mutations, accept DL-007 (+DL-012) - #37
Closed
jimutt wants to merge 3 commits into
Closed
Read run state directly, delegate mutations, accept DL-007 (+DL-012)#37jimutt wants to merge 3 commits into
jimutt wants to merge 3 commits into
Conversation
…12 amends: correct the script list) reads are a direct JSON parse; writes go through one bash argv path into the skill scripts, so there is exactly one implementation of every transition. Unknown run/item statuses and wrong schemaVersion are rejected at the read boundary; stderr is surfaced verbatim so blocked operator questions survive the process boundary. Review caught that the first draft passed flag-only fields positionally to three scripts and that verify-item.sh was not actually called. The amended list in DL-012 (verify-hashes, next-item added; verify-item dropped) is what the module delegates to, and the new tests cover the flag-argv shape so this doesn't regress. DL-012 exists because the review finding arrived after acceptance, and PRACTICES.md forbids body edits on accepted records — amends exists precisely for this. Co-Authored-By: Claude Opus 5 <noreply@pi.dev> Generated-By: pi 0.84.2
Until now an unknown argument printed only its own token, so a positional call to a flag-only script gave you Unknown option: probe with no shape to correct it. The extension will shell into these scripts, which makes unhelpful failure output agent-visible rather than merely user-annoying. Every flag-rejecting branch now falls through to a shared usage() that prints the caller script's header comment. The helper lives in common.sh with the same behavior for all goal scripts; the only bespoke change is create-run.sh defaulting to usage rather than an inline string. The sed range now stops at the first non-comment line so short-header scripts do not leak literal code into usage output. Byte-identical shadow copies refreshed. Co-Authored-By: Claude Opus 5 <noreply@pi.dev> Generated-By: pi 0.84.2
Co-Authored-By: Claude Opus 5 <noreply@pi.dev> Generated-By: pi 0.84.2
Owner
Author
|
Superseded by feat/pi-harness-extension — all commits from this branch are merged there. See #41 for the findings log on top. |
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.
What
The extension reads run state directly and delegates every mutation to the skill scripts. Reads are a pure JSON parse; writes go through one bash argv path, so there is exactly one implementation of every transition. Unknown run/item statuses and wrong schemaVersion are rejected at the read boundary; stderr is surfaced verbatim so blocked operator questions survive the process boundary.
The review caught that the first draft passed flag-only fields positionally to three scripts and that verify-item.sh was not actually called. DL-012 amends DL-007 with the corrected script list.
Also includes: unknown-argument errors across all goal scripts now print the script's usage from its header comment, via a shared helper in common.sh.
Stacks on #36.