Skip to content

fix: fail the multi-command check-cmd records on any failed check - #1007

Merged
kyle-sexton merged 1 commit into
mainfrom
fix/ecosystem-check-cmd-status
Nov 14, 2026
Merged

kyle-sexton merged 1 commit into
mainfrom
fix/ecosystem-check-cmd-status

Conversation

@kyle-sexton

Copy link
Copy Markdown
Member

No related issue: corrects a defect in the ecosystem records merged in #1002, found by the review of the same records in melodic-software/ci-workflows#1092.

Summary

The check-cmd of the cross-cutting and yaml records listed one command per line. Run as one shell string, that returns only the last command's status, so a failing typos, gitleaks, editorconfig-checker or actionlint was hidden whenever the last tool passed.

Fix

Each command now records its failure and the next still runs; the string's status is non-zero if any failed (rc=0, || rc=1 per command, test "$rc" -eq 0 last). An empty $EC_BIN fails with a message naming it. No tool, flag, argument or order changed.

Verification

  • An independent review diffed the before and after command lists: identical apart from the status handling.
  • Each check-cmd was extracted with yq and run under bash -c with stub tools: exit 0 when all pass; exit 1 when any single tool fails, with every later command still run.
  • Both records validate against the ecosystem-commands schema.
  • Not run against this tree with the real tools.
  • Known limit: under set -u with EC_BIN unset (not empty) the guard aborts instead of printing its message. The run still fails. /toolchain:lint sets EC_BIN="" before use, so the case needs a caller that skips that step.

Related

session: GitHub Support

🤖 Generated with Claude Code

The cross-cutting and yaml ecosystem records ran one command per line,
so the string returned only the last command's exit status and an
earlier failure (typos, gitleaks, an empty $EC_BIN, actionlint) read as
a pass. Each command now sets rc=1 on failure, an empty $EC_BIN fails
by name, and the string ends with test "$rc" -eq 0 so it gives the same
status under bash -c or inside a larger script. Tools, flags and order
are unchanged.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 14, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-14T07:54:07.833608Z 295ed14 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@github-actions

Copy link
Copy Markdown

claude-security-review reviewed 295ed142812bfee8425e208b73af29d7d12c6b85: 0 finding(s), 0 as inline comments.

No security issues found in PR #1007 (head 295ed14).

The PR changes two local lint-command records, .claude/ecosystems/cross-cutting.yaml and .claude/ecosystems/yaml.yaml. Each check-cmd now accumulates an exit status (rc=1 after any failed tool) and ends with test "$rc" -eq 0, so a failure in any check fails the command.

  • Trust controls: none of the changed files is a trust control, a trusted path, a manifest, or an instruction surface, so the instruction-deletion lens does not apply.
  • Fail-closed behavior: the change makes checks stricter. The gitleaks secret scan, typos, editorconfig-checker, lychee, actionlint and zizmor can no longer be masked by a later command's success. A missing EC_BIN now fails the run instead of running an empty command.
  • Injection: $EC_BIN is expanded only inside a [ -n ... ] guard and a quoted command position. The <files> placeholder is unchanged from the base. The commands run on the developer's own checkout and take no PR-controlled input beyond what the base already did.
  • Not consulted: docs/contracts/instruction-exception-register/README.md was not read, because the diff removes no standing instruction.

critical-findings: 0

@github-actions

Copy link
Copy Markdown

claude-review reviewed 295ed142812bfee8425e208b73af29d7d12c6b85: 0 finding(s), 0 as inline comments.

No findings.

I reviewed the full diff (two ecosystem records, .claude/ecosystems/cross-cutting.yaml and .claude/ecosystems/yaml.yaml) at head 295ed14. I did not run the commands.

  • Status handling: The rc=0, || rc=1 per command, test "$rc" -eq 0 pattern reads as correct. Every check still runs and any single failure makes the string exit non-zero. No tool, flag, argument or order changed, and the <files> placeholder in the yaml record is untouched.
  • Empty EC_BIN: The new guard fails with a named message instead of running "$EC_BIN" as an empty command. The PR body states the set -u with EC_BIN unset limit, and the run still fails there.
  • Sibling records: The other ecosystem records use a single command, or && in the python record, so the same last-status defect does not occur there. The && chain stops at the first failure.
  • Consumer assumption: The change relies on the consumer running check-cmd as one shell string. The PR body states this, and the consumer is outside this repository, so I could not confirm it.
  • Closing issue: None; the PR declares No related issue:, so no acceptance criteria apply.
  • Manifests, paved paths, settled threads, prior findings: None apply to this diff.
  • PR body: The PR body follows the contract in .claude/rules/pr-body-contract.md.
  • Verification: The PR's stub-tool runs and yq extraction are author-claimed and I did not independently verify them. The author also states the change was not run against this tree with the real tools.

Verifier dropped 0 of 0 candidates.

@kyle-sexton
kyle-sexton merged commit 65efff8 into main Nov 14, 2026
22 checks passed
@kyle-sexton
kyle-sexton deleted the fix/ecosystem-check-cmd-status branch November 14, 2026 08:17
kyle-sexton added a commit that referenced this pull request Nov 16, 2026
…n in the records (#1031)

Refs: melodic-software/claude-code-plugins#15719

## Summary

Two ecosystem records merged in #1002 and #1007 no longer match what CI
runs. #982 re-pinned every ci-workflows composite to v0.74.0
(`944d346`), and that release replaced the actionlint composite's
rhysd/actionlint 1.7.12 with the kjanat/actionlint fork 1.17.0. The
cross-cutting record also ran a different gitleaks command than CI's
composite. This change fixes `.claude/ecosystems/yaml.yaml` and
`.claude/ecosystems/cross-cutting.yaml` only. No other record changes,
and no record's command changes apart from gitleaks.

## Fix

| Record | Before | After | Source CI runs |
|---|---|---|---|
| yaml | install hint `rhysd.actionlint`, no `tool-pin` |
kjanat/actionlint fork v1.17.0 with its SHA-256; `tool-pin` actionlint
1.17.0 | ci-workflows `actionlint/action.yml` at `944d346` (version and
sha256 defaults), called by `pr-require-checks.yml` check-github-actions
|
| yaml | install hint `pip install zizmor`, no pin | `uv tool install
zizmor==1.30.0`; `tool-pin` zizmor 1.30.0; notes state `--offline` is
narrower than CI's online audits | ci-workflows `pr-audit-workflows.yml`
at `@main` (`version` default v1.30.0, `persona` regular); this
repository passes `fail-on-severity: low` |
| cross-cutting | `gitleaks detect --source . --redact --no-banner
--no-git` | `gitleaks dir . --config .gitleaks.toml --no-banner
--redact`; `tool-pin` gitleaks 8.30.1 | ci-workflows
`gitleaks/action.yml` defaults (`scan-mode: dir`, `path: '.'`, version
8.30.1) and `gitleaks/scan.sh` args; this repository passes `config:
.gitleaks.toml` |
| cross-cutting | pins: lychee only | adds typos 1.50.3 and
editorconfig-checker 4.0.2 | `typos/action.yml` and
`editorconfig-checker/action.yml` version defaults at `944d346` |

Differences that stay, listed for the owner:

- markdownlint-cli2: CI's lint step runs the composite's default 0.23.3,
while `npm ci` installs the `package.json` pin 0.24.0 for the contract
tests. The record keeps 0.24.0, as #1002 chose.
- ruff and pyright: CI's lint steps run the composite defaults (ruff
0.16.5, pyright 1.1.411), while the contract tests use the inline
0.15.14 and 1.1.409. The python record keeps the inline pins.

Neither moved since #1002. A single `tool-pin` cannot follow two
versions.

## Verification

- Schema: `check-jsonschema --schemafile
docs/contracts/ecosystem-commands/ecosystem.schema.json`
(claude-code-plugins `origin/main`) over all nine records on this branch
printed `ok -- validation done`.
- Method: a throwaway `git clone --shared` holds #1002's recent range,
`25163b5..9ce192b`, with `refs/remotes/origin/main` at the base. This
branch's records are copied in, and every tool runs with `env -C
<clone>`. Toolchain skill text is 1.4.0.
- Run 1, `/toolchain:check all`, 11:29 PM to 11:31 PM EST 2026-11-15.
Overall line: `Overall: FAIL (2 of 7 ecosystems failed)`.

| Ecosystem | Build | Test | Lint | Status |
|---|---|---|---|---|
| dotnet | — | pass | — | PASS |
| go | — | FAIL | — | FAIL |
| python | — | FAIL | — | FAIL |
| typescript | — | — | pass | PASS |
| bash | — | — | pass | PASS |
| powershell | — | — | — | — |
| markdown | — | — | pass | PASS |

- go fails on the suite's case [3] only: the machine has golangci-lint
2.15.0 and CI pins 2.12.2.
- python fails on `ruff.test.sh` [1] only, because the installed ruff is
not CI's 0.15.14. These are the same two failures as #1002's run 5.
- typescript: the install rule ran `npm ci --ignore-scripts`, and `git
status` and the diff were unchanged.
- The output contains no `skip (unresolved`. All seven ecosystems
resolved from `.claude/ecosystems/`.
- Run 2, `/toolchain:lint`, 11:31 PM to 11:33 PM EST. Overall line:
`Overall: PASS (5 of 5 ecosystems passed)` (typescript, bash, markdown,
yaml, cross-cutting).
- `gitleaks dir . --config .gitleaks.toml --no-banner --redact` found no
leaks.
- `zizmor --offline` over the three changed `.github` files reported no
findings.
- Installed versions differ from the new pins on this machine:
actionlint 1.7.12 rhysd, zizmor 1.32.0, typos 1.52.2 and
editorconfig-checker 3.11.1. The pins follow CI.
- The pre-commit hooks passed on the commit: editorconfig, typos,
gitleaks and the commit-msg convention.

## Related

- #1002 and #1007, which merged the records this change corrects
- #982, the v0.74.0 re-pin
- melodic-software/claude-code-plugins#15719,
melodic-software/claude-code-plugins#15703 (parent)
- The same fix in claude-code-proxy:
melodic-software/claude-code-proxy#409

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Claude Opus 5.5 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant