fix(skill-quality): read integer overrides as decimal and stop measuring YAML comments - #2002
Conversation
… comments Force base-10 parsing for accepted INTEGER overrides so a leading zero is not read as octal; the documented 0.01 default fraction keeps its leading zero. Make the shared skill_frontmatter::field trailing-comment strip quote-aware on the plain/flow branch only, since inside a block scalar a `#` is content. Drop the now-redundant sed strip from normalize_bool. Adds 7 regression cases. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
…ting-budget-overrides
…ting-budget-overrides
|
Bugbot is not enabled for your account, so this pull request was not reviewed. Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs. |
|
Claude finished @kyle-sexton's task in 1m 44s —— View job Security review complete
No security issues found. This PR is scoped to a bash/awk parsing correctness fix plus a documentation wording reconciliation — no GitHub Actions workflow, permissions, or trust-boundary changes are in the diff. What I checked specifically, given the change:
Confidence: high — the diff is small (2 scripts + tests + docs), self-contained, and the validate-then-convert ordering that closes the octal/injection concern is visible at each call site in the same file. |
|
Claude finished @kyle-sexton's task in 4m 30s —— View job Code review
This repo has a Octal fix ( Comment-stripping fix ( Docs fix ( Version/changelog. Tests. The 7 new cases in Not independently verified: I was unable to execute Bash in this session (script/test invocations were consistently blocked pending approval that never resolved), so I could not run the test suite, ShellCheck, or markdownlint myself. The PR's Testing section describes green runs of the full gate list — that is author-claimed and unverified by me; my review is based on static reading of the diff and cross-referencing the call sites by hand. No correctness, design, or test-coverage issues found beyond the one inline suggestion (nit-level, not blocking). |
|
Claude has reviewed this PR 5 times. The lane skips further automatic reviews after 5; deleting this comment resets the count. |
…ting-budget-overrides
|
Claude finished @kyle-sexton's task in 1m 22s —— View job Security review complete
No security issues found. No GitHub Actions workflow, permissions, secrets, or trust-boundary surface is touched by this diff — it's confined to two plugin scripts, their tests, and prose/metadata (docs, What I traced specifically, given the fix's shape:
Confidence: high. The diff is small and self-contained, and the validate-then-convert ordering that closes the arithmetic-expansion concern is directly visible at each call site in the same file, not inferred. |
|
Claude finished @kyle-sexton's task in 2m 50s —— View job Code review
Per Octal fix ( Comment-stripping fix ( Docs fix ( Tests. Verified the math by hand for all three new fixtures: the quoted-comment fixture ( One nit from this PR's prior review round — the unanchored substring match in Version/changelog. Not independently verified: I did not execute the test suite, ShellCheck, or markdownlint myself — the PR's Testing section (green run of the full gate list) is author-claimed and unverified by me. My review is based on static reading of the diff, hand-tracing call sites, and hand-computing the test fixture arithmetic. No correctness, design, or test-coverage issues found beyond the one pre-existing nit noted above (non-blocking). |
Main shipped 0.13.0 and 0.14.0 while this work sat, so the branch's entry is renumbered to 0.14.1 and stacked above them. Keeps main's description, which documents the eval-quality lint this branch does not touch. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
|
Claude finished @kyle-sexton's task in 57s —— View job Security review complete
No security issues found. This diff (6 files, What I traced specifically, given the fix's shape, against
Confidence: high. The diff is small and self-contained, and the validate-then-convert ordering that closes the arithmetic-expansion concern is directly visible at each call site in the same file, not inferred. |
|
Claude finished @kyle-sexton's task in 4m 30s —— View job Code review
Per Octal fix ( Comment-stripping fix ( Docs fix ( Tests. Hand-computed the arithmetic for all three new comment-stripping fixtures (quoted: 5+3+7=15, plain: 5+3+11=19, block: 9) and they match the asserted aggregates. The octal fixtures correctly isolate each call site and 14d correctly guards that Version/changelog. Worth noting for the record: Pre-existing, still open: the unanchored substring assertions in Not independently verified: I could not execute Bash for test/lint runs in this sandbox (network and several shell operations required approval that wasn't available), so the PR's Testing section (green run of the full gate list, No correctness, design, or test-coverage issues found. The only outstanding item is the pre-existing, non-blocking test-assertion nit noted above. |
…ting-budget-overrides
|
Claude finished @kyle-sexton's task in 2m 7s —— View job Code review
Per Octal fix ( Comment-stripping fix ( Docs fix ( Tests. The 7 new cases correctly isolate each of the three octal call sites, the per-entry cap, and the fraction guard (0.01 surviving untouched), plus three comment-stripping fixtures (quoted, plain-with-non-comment- Still open, non-blocking: the unanchored substring assertion flagged in an earlier review round ( Version/changelog. Not independently verified: I did not execute the test suite, ShellCheck, or markdownlint in this session — the PR's Testing section (green run of the full gate list) is author-claimed and unverified by me. This review is based on static reading of the diff and hand-tracing the call sites, awk logic, and test fixture arithmetic. No correctness, design, or test-coverage issues found beyond the one pre-existing, non-blocking test-assertion nit noted above. |
|
Claude finished @kyle-sexton's task in 54s —— View job Security review complete
No security issues found. Diff reviewed against What I traced, given the fix's shape:
Confidence: high. The diff is small and self-contained, and the validate-then-convert ordering that closes the arithmetic-expansion concern is directly visible at each call site in the same file, not inferred. This matches the conclusion of the prior security-review passes on this PR — no new findings on this iteration. |
…assertions `budget:.*8 chars (override` also matched `18 chars` or `28 chars`, since `.*` absorbs the leading digit. Safe today — no path through the fix produces those values — but it left the assertion unable to catch an off-by-something regression in to_decimal, which is the whole point of the case. Requires a non-digit or line start ahead of the value. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
|
Claude finished @kyle-sexton's task in 1m 50s —— View job Security review complete
No security issues found. This PR (6 files: What I traced specifically, reading the code directly at HEAD (
Confidence: high. The diff is small and self-contained, and the validate-then-convert ordering that closes the arithmetic-expansion concern is directly visible at each call site in the same file, not inferred. |
|
Claude finished @kyle-sexton's task in 3m 27s —— View job Code review
Per The previously-flagged nit is now fixed. Commit Independent re-verification of the core fix (static, hand-traced):
Not independently verified: Bash execution was blocked pending approval that never resolved in this sandbox (same limitation noted in earlier review rounds on this PR), so I could not run the test suite, ShellCheck, or markdownlint myself. The PR's Testing section (green run of the full gate list) is author-claimed and unverified by me. This review is based on static reading of the diff and hand-tracing call sites, awk logic, and the regex fix. No correctness, design, or test-coverage issues found. The single outstanding nit from earlier rounds is resolved in this diff. |
Three stranded post-merge review findings on the
skill-qualityplugin, plus therepository-level doc contradiction filed alongside them. Reviews posted after their PRs
merged were invisible to the merge gate, so these sat unread.
Zero-padded integer overrides were parsed as octal
require_positive_number's^[0-9]+$accepts a zero-padded value, but bash arithmetic andprintf %dthen read it in base 8. Reproduced three ways againstorigin/mainin adetached worktree:
CHECK_SKILL_LISTING_BUDGET_CHARS=08—printf: 08: invalid octal number, the budgetrendered as
0, and the report still announcedOKand exited 0.CHECK_SKILL_LISTING_BUDGET_CHARS=0123— budget silently became 83.CHECK_SKILL_LISTING_MAX_DESC_CHARS=010— entries capped at 8 instead of the requested 10.Accepted integer overrides are now forced to base 10 at the one place the digits become a
number. All three
require_positive_number ... intcall sites are covered. The ratio andfraction overrides are deliberately left alone:
0.01is the documented default fractionand must keep its leading zero, and both reach only
awk, which has no octal input.CHECK_SKILL_LISTING_CHARS_PER_TOKENis likewise untouched because it never reaches$(( ))or
%d. No other script in this plugin takes a numeric environment override, so there is nosibling occurrence of the pattern left behind.
A trailing YAML comment was measured as part of the listing scalars
skill_frontmatter::fieldreturned the comment along with the value, which also hid thesurrounding quotes from
strip_quotesso the quoting was counted too. A fixture withcommented
descriptionandwhen_to_usescalars measured 52 characters against a true 15,producing false overflow warnings and wrong contributor sizes.
The fix went into the shared helper rather than the reporter, because
check-skill.shreads the same fields through it — the per-skill entry cap (Check 2) and the
trigger-preservation diff had the same defect. Stripping is quote-aware and confined to the
plain/flow branch: inside a block scalar a
#is content, such as a markdown heading in adescription: |body.normalize_bool's ownsedcomment strip is now redundant and was removed, along with thecomment asserting that comment-stripping is "never applied to
description/when_to_use". It has exactly one caller and that caller sources its value throughskill_frontmatter::field, so nothing loses the strip.Blast radius was measured rather than predicted: every
SKILL.mdunderplugins/was runthrough both the old and the new extractor and the measured
description/when_to_uselengths are identical across the repo — no real skill's measurement moves.
The fresh-eyes rule contradicted the dispatch ladder
docs/PLUGIN-PHILOSOPHY.mdstated the normative rule as requiring "a named subagent" whileits own dispatch ladder makes a generic fresh-context subagent the default and its
named-agent bar says a named agent is earned, not default. An author following the rule
would create a named agent unnecessarily.
Resolved toward the ladder rather than hedged, because that is what the repo actually
enforces: the delegation-wording detector in
check-skill.shaccepts a generic worker —it matches
fresh-contextplus any of agent/subagent/worker/advisor/reviewer/verifier/dispatch/delegate — and never requires a named agent.
docs/topics/fresh-eyes-checkpoint-audit/PLAN.mdspecified this same reconciliation ("generic or named"); it was applied to the preceding
paragraph and missed on the rule sentence itself. The author-facing spec
skills/check/reference/fresh-eyes-declarations.mdis doctrine-agnostic and needed no change.Folding this nine-word documentation clause into the plugin PR instead of buying a second
full CI cycle is a deliberate, operator-approved deviation from one-PR-per-plugin.
Also verified, no change needed
The fourth finding in this batch reported two
versionmembers inplugins/skill-quality/.claude-plugin/plugin.json. Already fixed on main bydcfa7c8b70(#1494); the manifest carries exactly one. Recorded here so the thread resolves against
evidence rather than silence.
Testing
Seven regression cases added to
check-listing-budget.test.shcovering each octalmanifestation, the decimal fraction that must keep working, the quoted and plain comment
forms, a
#that is content rather than a comment, and a#inside a block scalar.Gates run green from the worktree root: the listing-budget and
check-skillsuites,run-plugin-tests.sh,check-changelog-parity.sh --check/--check-bump/--check-order,check-changed-skills.sh,check-shell-portability.sh(+ its suite),check-contract-slice-prune.sh --check/--check-diff,check-contract-clause-coverage.py,ShellCheck over the three changed scripts, markdownlint over the two changed docs, and the
CI invocation
check-listing-budget.sh plugins/*/skills.Related
Refs #1938 — the stranded-findings triage sweep these threads came from.
No linked issue