Skip to content

fix(playbooks): let skill-authoring load when Bash is not granted - #16230

Merged
kyle-sexton merged 1 commit into
mainfrom
fix/16145-skill-authoring-load
Nov 14, 2026
Merged

kyle-sexton merged 1 commit into
mainfrom
fix/16145-skill-authoring-load

Conversation

@kyle-sexton

@kyle-sexton kyle-sexton commented Nov 14, 2026 •

Copy link
Copy Markdown
Member

Closes #16145

Summary

playbooks:skill-authoring failed to load in every eval run that grants no Bash. Its prose shows the dynamic-context injection syntax inside a code span written as !`command`: the ! sits right after whitespace, so the loader treats it as a pre-computed command, runs its permission check, and refuses the load with Shell command permission check failed for pattern "!command": Permission to use Bash has been denied. The six skill-authoring-* eval cases therefore scored a session without the skill on both sides of any compare.

Fix

One character in plugins/playbooks/skills/skill-authoring/SKILL.md line 182: the code span changes from !command to ``!`command` ``, so a backtick, not whitespace, sits directly before the !. The rendered text still shows readers the !`command` syntax. A patch changelog fragment for playbooks is under .changes/playbooks/.

Which escape the loader ignores, and why: the loader recognizes the inline form only when its ! is at a line start or after whitespace. The evals validator encodes that rule at plugins/evals/skills/validate/scripts/validate-cases.py:247-258 (PRECOMPUTED = re.compile(r"(?:^|(?<=\s))![^\n]+|^[ \t]*```!", re.MULTILINE)), from the 2026-11-14 compare where skill-authoring's `` !command` `` failed every load. `plugins/evals/skills/plugin-eval/SKILL.md:463` writes the same syntax as ``!`command` `` (backtick directly before the `!`) and loaded in every one of its runs in that compare. The fixed line now uses that same form.

Sweep of every other tracked SKILL.md (done-when item 3): git grep -n -E for a ! after whitespace or at a line start followed by a backticked command, plus a ```! fence opener, over *SKILL.md. 98 lines in 60 files hit. Every hit is a deliberate pre-computed line: a label followed by a command with an || echo fallback (for example plugins/code-metrics/skills/audit/SKILL.md:15), a standalone ! command line (for example plugins/instruction-placement/skills/audit/SKILL.md:29), a real ```! block (plugins/harness-memory/skills/stateless/SKILL.md:16, plugins/knowledge/skills/course-digest/SKILL.md:13, plugins/knowledge/skills/video-digest/SKILL.md:14, plugins/performance/skills/go-faster/SKILL.md:40), or the eval fixture plugins/session-flow/evals/recall-still-reports-reopened-bug/work-items-stub/skills/track/SKILL.md:13, whose command is the point of the stub. No other SKILL.md carries the syntax in prose, so nothing else changed.

Verification

  • python3 -I plugins/evals/skills/validate/scripts/validate-cases.py plugins/playbooks/evals: before (origin/main content), 0 FAIL and 6 WARN lines skills/skill-authoring/SKILL.md has a pre-computed context line, which needs Bash, one per skill-authoring-* case. After, 0 FAIL and none of those 6 warnings; the remaining WARNs (sample calibration, missing samples, a Bash grant in update-check-runs-pack-scripts) are unchanged.
  • scripts/check-changelog-fragments.sh --check-required origin/main: every fragment-mode plugin changed has a fragment. --check: all 5 fragments valid.
  • scripts/check-changed-skills.sh origin/main: CHECK-SKILL skill-authoring: PASS, 0 errors, 3 warnings that predate this change (no Gotchas surface, description length, body length); update.test.sh passed.
  • scripts/check-affected.sh --no-fetch: 16 passed, 2 skipped. git diff --check origin/main..HEAD: clean. typos on both changed files: clean.
  • Eval, before and after, per docs/review/skills-and-agents.md: the six skill-authoring-* cases on sonnet. BEFORE is expected to show the load failure (Shell command permission check failed and no skill body in the trace); AFTER is expected to show the skill body loaded and no such line.

Eval record (registered before the scored runs)

This pull request carried the do-not-merge label from its opening until this record was added.

Before: 4f2dcaaff35e8f9fccc6a9f4d82a5830ab17a5c5 (main). After: 798822b8a805f3716d1d8592e6f2d8c710176bc7 (this head). The two plugin copies differ in skills/skill-authoring/SKILL.md only. The six skill-authoring-* cases, 6 runs per case per side on sonnet, judge claude-opus-5-5, --ablation none, no tool grant beyond each case's own allowed_tools: [Read, Skill], Claude Code 2.1.325. 72 runs, 4.64 USD list, no run error, none partial, nothing rerun. Figures re-derived by the hub session from the eight result files and their traces.

Before After
run-validity.py --runs 6 INVALID in all four files: "the skill failed to load" in 36 of 36 runs VALID in all four files, check skill loaded: PASS
Traces with Shell command permission check failed for pattern 36 of 36 0 of 36
Runs whose Skill call returned the skill body 0 of 36 36 of 36
Session tools Task, Glob, Grep, Read, Skill, TaskStop, ToolSearch (no Bash) the same

Per case, the six scores, the mean, and grader passes of 6:

Case Before After
background-left-out 0.5 x6, mean 0.50; reads-criteria 0 1 x6, mean 1.00; reads-criteria 6, history-dropped 6
judgment-rule-no-reason 0.5 x6, mean 0.50; reads-criteria 0 1 x6, mean 1.00; both graders 6
reason-for-required-step 0.5 x6, mean 0.50; reads-criteria 0 1 x6, mean 1.00; both graders 6
reason-scopes-narrow-rule 0.5 x6, mean 0.50; reads-criteria 0 1 x6, mean 1.00; both graders 6
self-evident-rule-no-reason 0 x6, mean 0.00 0.5 x6, mean 0.50; reads-criteria 6, no-appended-reason 0
style-output-labeled-pairs 0 x6, mean 0.00 1, 0.5, 0.5, 0.5, 0.5, 0.5, mean 0.583; reads-criteria 6, labeled-pairs-and-rule-line 1

The registered bar for the after side, written before the runs, is met: every file VALID with the skill loaded in every run that calls it. With the skill loading, reads-criteria goes from 0 of 36 to 36 of 36. Two cases stay under 1.00 on a second grader (no-appended-reason 0 of 6, labeled-pairs-and-rule-line 1 of 6); those graders could not be measured while the skill never loaded, and what they show now is outside this change.

One earlier batch is on record and counted on neither side: the first registration reused another compare's --allow-tools Bash Write Edit, which grants Bash, so its 6 before-side runs loaded the skill and ran the example line as a command. The second registration dropped the grant and says why.

Related

session: GitHub Support

🤖 Generated with Claude Code

Lane-Activity: work-resolve-issue/resolve-issue
@kyle-sexton kyle-sexton added the do-not-merge Hard merge gate: do not merge while applied. label Nov 14, 2026
@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-14T20:57:10.190472Z 798822b 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
Contributor

claude-security-review reviewed 798822b8a805f3716d1d8592e6f2d8c710176bc7: read 2 of 2 changed file(s); 0 finding(s), 0 as inline comments.

Security review: no findings

I read both changed files in full: the changelog fragment and the one-line edit to plugins/playbooks/skills/skill-authoring/SKILL.md. Neither matches a trusted-path glob.

What the change does. In a prose code span, !`command` becomes !`command` . Before, the ! sat right after a space, so the skill loader read it as a dynamic-context injection line. It tried to run the placeholder command, and the load failed in any session without Bash. Now a backtick sits directly before the !, so the loader doesn't treat it as a command line.

Security assessment.

  • The change takes away one thing the skill tried to run when it loaded. It runs nothing new.
  • It removes no instruction. The guidance text means the same thing as before.
  • It touches no trust control, token scope, merge hold, kill switch, workflow, or plugin manifest. No .claude-plugin/*.json changed.
  • The changelog fragment is plain text that runs nothing.
  • The PR description contains no embedded instructions aimed at this lane.

Spend: none beyond normal lane runs. The PR plans eval runs (6 cases × 6 runs on sonnet), which use prepaid API credit. That isn't a billed resource.

critical-findings: 0

@github-actions

Copy link
Copy Markdown
Contributor

claude-review reviewed 798822b8a805f3716d1d8592e6f2d8c710176bc7: read 2 of 2 changed file(s); 1 finding(s), 0 as inline comments.

Code review: PR #16230, a one-character fix so skill-authoring loads without Bash

Scope: I read both changed files in full: plugins/playbooks/skills/skill-authoring/SKILL.md and the new .changes/playbooks/ fragment. Neither matches a trusted-path glob.

The code change is correct. I checked these things myself with Read and Grep. I ran no evals.

  • On SKILL.md:182, the character before ! is now a backtick, not whitespace.
  • The validator's PRECOMPUTED regex ((?:^|(?<=\s))![^\n]+|^[ \t]*!`, [`validate-cases.py:258`](https://github.com/melodic-software/claude-code-plugins/blob/798822b8a805f3716d1d8592e6f2d8c710176bc7/plugins/evals/skills/validate/scripts/validate-cases.py#L258)) finds no match anywhere in the head `SKILL.md`. The ```` ! ```` example on the same line is not at a line start, so it does not match either.
  • In CommonMark, the new span ``!`command` `` still shows readers !`command`. That meets the issue's "prose still shows readers the injection syntax" criterion.
  • The patch bump in the fragment fits a docs-only fix.

Closing issue #16145: run-based criteria not yet met (blocking, PR-wide). These three done-when items have no evidence in the PR yet. The body says EVAL RECORD: pending:

  • "The cause is confirmed by a run, not by reading: one skill-authoring-* case run with the line changed loads the skill (the trace shows the skill body, and no Shell command permission check failed line)."
  • "6 runs of the six skill-authoring-* cases on sonnet at the fixed head: the skill fires in every should-trigger run, recorded in the pull request with the per-case scores."
  • "The before/after eval docs/review/skills-and-agents.md requires for a skill-body change is in the pull request body; the BEFORE side is expected to show the load failure, and the body says so."

Right now the body gives only what the BEFORE and AFTER runs are expected to show. Its validator, changelog and skill-check results are the author's claims, and I did not re-run them. The PR says it carries do-not-merge until the record is added. Before merge, add the per-case scores and the before/after traces at this head.

Sweep of other SKILL.md files: the PR lists 98 hits in 60 files and calls every one an intended pre-computed line. That claim is the author's; I did not re-run the sweep, since it is outside the changed files.

Tests: if this regressed, the validator would only raise a WARN, not fail. The issue puts that gap out of scope ("filed separately"), so I report nothing for it.

There are no embedded instructions in the PR context, no settled threads and no earlier findings from this lane. There are no plugin manifest changes and no cost or hold class.

Verifier dropped 0 of 1 candidates. This was a single-candidate review, so no verifier subagent ran.

@github-actions

Copy link
Copy Markdown
Contributor

The pr-verify verifier failed head 798822b8a805f3716d1d8592e6f2d8c710176bc7. What it wrote, as data:

What it wrote (22 lines)
Summary: Issue #16145: the one-character fix in
  plugins/playbooks/skills/skill-authoring/SKILL.md:182 looks right. The code span now opens with a
  backtick directly before the `!`, so the `!` no longer follows whitespace, and the page still
  shows readers the injection syntax. The PR body names the escape and cites the validator rule and
  plugin-eval/SKILL.md:463 (done-when item 2). It also lists what the sweep of the other SKILL.md
  files found (item 3). The changelog fragment is valid, and every CI job on the judged head that
  runs a suite passed (e.g. Check Skills:
  https://github.com/melodic-software/claude-code-plugins/actions/runs/43640072773/job/132585601220).
  CI Status failed, but that job only sums the others and is not test evidence. The capture was
  blocked, which counts neither for nor against the change. Three done-when items are still missing,
  though. Items 1, 4 and 5 each ask for an eval run recorded in the pull request, and the PR body
  says "EVAL RECORD: pending" and only states what BEFORE and AFTER are expected to show. The spec
  has no person_checks or credited_siblings that would excuse these items, so the spec is not
  delivered.
- PR body: done-when item 1 is not met. Run one skill-authoring-* case at this head and record in
  the body that the trace shows the skill body and no 'Shell command permission check failed' line.
- PR body: done-when item 4 is not met ('EVAL RECORD: pending'). Run 6 runs of each of the six
  skill-authoring-* cases on sonnet at the fixed head and record the per-case scores, showing the
  skill fires in every should-trigger run.
- PR body: done-when item 5 is not met. Add the actual before/after eval results that
  docs/review/skills-and-agents.md requires, with the BEFORE side showing the load failure, in place
  of the expected outcomes now written there.

This pull request leaves the merge queue, and ci-status holds it out while it carries pr-verify-failed. A pr-verify pass removes the label, at a new commit or at this same head: once a trusted person edits the body, and only trusted people have edited it since the fail, this head is judged again, so a fail on the body or the issues it links needs only the body fixed, no new commit.

@github-actions github-actions Bot added the pr-verify-failed pr-verify failed this head; a pass at a new commit, or after a trusted body edit, removes it. label Nov 14, 2026
@kyle-sexton kyle-sexton removed the do-not-merge Hard merge gate: do not merge while applied. label Nov 14, 2026
@github-actions github-actions Bot removed the pr-verify-failed pr-verify failed this head; a pass at a new commit, or after a trusted body edit, removes it. label Nov 14, 2026
@kyle-sexton
kyle-sexton added this pull request to the merge queue Nov 14, 2026
Merged via the queue into main with commit 9bf5c66 Nov 14, 2026
119 of 124 checks passed
@kyle-sexton
kyle-sexton deleted the fix/16145-skill-authoring-load branch November 14, 2026 21:30
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.

fix(playbooks): skill-authoring fails to load when Bash is not granted

1 participant