Repository navigation
fix(harness-ops): read plugin install's unsetOptionCount before the message sentence - #18169
Conversation
…essage sentence A probe of `claude plugin install --json` on Claude Code 2.1.330 (scratch CLAUDE_CONFIG_DIR) shows the result carries `unsetOptionCount` when an option is unset, and `configApplied` when --config is passed. No field gives the required count or a disabled-by-default install. unset_user_config_of now takes the count from the field and still reads the "(M required)" count from the message, falling back to the sentence on a CLI with no field. The cli_json and unset_user_config_of claims, their Basis and As-of lines, and sync.md state what the probe showed. Two 2.1.330 result rows join the recorded fixtures, and the stub and tests cover the field with and without the sentence. Closes #17894 Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01RAoAtV6H7kcRVG5xeX1rtT
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
claude-security-review reviewed Security review: no security issues foundI read the whole diff for all 5 changed files. None of them matches a trusted-path glob, and the PR touches no plugin manifest, workflow, token request, merge hold or trust control. What changed: In Why it is safe:
The PR description holds no embedded instructions aimed at this review. There were no earlier reviews of this PR to account for (this was not a blocking-only review). critical-findings: 0 |
|
claude-review reviewed No findings. The change makes Checked logic:
Checked tests:
Closing issue #17894, Done-when items:
Path-scoped rules:
Loosened checks:
Other:
Verifier dropped 0 of 0 candidates. |
Post-merge mutation testingKilled 5, survived 2, timeout 0, no coverage 0, invalid 0, not run 0.
Surviving mutants
The run's summary has the full report. |
Closes #17894
Summary
claude plugin install --jsonnow prints anunsetOptionCountfield when an install leaves userConfig options unset.sync-run.shread the count only from the sentence inmessage, so an install whose message lacked the sentence would drop out of "Action needed". It now reads the field first and still takes the "(M required)" count from the sentence, since no field carries it.Fix
plugins/harness-ops/skills/plugins/scripts/sync-run.sh:unset_user_config_oftakesoptions_unsetfromunsetOptionCountwhen it is a positive number, otherwise from the sentence. It falls back to the sentence alone on a CLI that prints no result line. Thecli_jsonandunset_user_config_ofClaim, Basis, As-of and Recheck lines state what the 2.1.330 probe showed, and Basis links the JSON result format.plugins/harness-ops/skills/plugins/scripts/fixtures/cli-json-results.jsonl: two recorded 2.1.330 result rows,install-unset-countandinstall-config-partial.plugins/harness-ops/skills/plugins/scripts/sync-run.test.sh: the stub can emitunsetOptionCount, a recorded-shape assert covers the new row, and two cases cover the field without the sentence and with it (the required count kept).plugins/harness-ops/skills/plugins/context/sync.md: the install-facts paragraph names the field..changes/harness-ops/: patch fragment.Verification
CLAUDE_CONFIG_DIR: an install with two unset options (one required) printed"unsetOptionCount":2, one with a--configpartial printed"configApplied":true,"unsetOptionCount":1, and a fully configured install printed neither field. The recorded rows are in the fixture file above.sync-run.test.sh: 703 PASS,All tests passed, including all 8recorded shapeasserts.scripts/selection-audit.sh trace --strictonsync-run.test.sh: "No gap: every file a traced suite read selects that suite."shellcheck,markdownlint-cli2andscripts/check-changelog-fragments.sh --checkpass.cache-content-check(30 cases, 0 failed),converge-planandnormalize-enabled-pluginspass.fleet-state(97 cases, 10 failed, allprojectPathIsHome) andreset-refresh(3 assertions failed, HOME-tree checks) fail the same way on unmodified main in this environment, so they predate this change. Neither script is touched here.Related
🤖 Generated with Claude Code
https://claude.ai/code/session_01RAoAtV6H7kcRVG5xeX1rtT