Feat/kyaml pilot provisioning convert - #1133
Merged
Merged
Conversation
YAML-POLICY Y-1: a verdict about a workflow must come from a parser.
Each of these gates read `uses:`/`permissions:` by line grep, which only
sees block style. On a KYAML workflow they either falsely failed (the
quote and comma were captured into the ref) or went blind (a pin inside
`{ uses: ... }` was never seen):
- validate-actions-lock.sh, lock-selfcheck.sh, check-action-pins-resolve.sh,
update-actions-lock.sh: refs come from yq; an unparseable file fails
closed instead of contributing zero refs.
- check-workflow-duplicate-keys.sh: flow documents are normalised with
yq -P before the line scanner runs (yq keeps duplicates, so the
scanner still sees them).
- governance-reusable.yml: top-level permissions via yq has("permissions"),
with a warned grep fallback on a runner without yq.
- Mustfile actions-sha-pinned: optional quote/comma in the pattern.
- lock-selfcheck.sh: its existing MPL-2.0 SPDX line moves from line 41
to line 2 so the staged SPDX hook sees it (identifier unchanged).
Known answers on main's block-style tree: identical ref sets for
validate-actions-lock (29) and lock-selfcheck (111 pairs);
check-action-pins-resolve drops exactly two `# uses:` comment examples
that never execute. New KYAML cases and mutants fail against the old
scripts and pass against the new ones.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01W5CoaksP2Bg21HpDCgFgwS
The pre-commit/pre-push permissions hook grepped `^permissions:`, which
never matches a KYAML workflow (every key sits inside `{ ... }`), so a
KYAML file that does declare permissions was rejected. Ask yq
has("permissions") instead; an unparseable file is an error, not a
pass. Without yq the grep is kept with a warning -- it can only
false-fail KYAML, never false-pass.
Known answer: identical output to the old hook on all 58 of main's
workflows. scripts/tests/validate-permissions-test.sh: 6/6; the old
hook fails its KYAML positive case.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01W5CoaksP2Bg21HpDCgFgwS
Single-file pilot of YAML-POLICY Y-3, produced verbatim by `yq -p yaml -o kyaml '.'` (yq v4.53.3). Not the #1023 scope ruling. Verified locally: - data-equal: sort_keys JSON of block and KYAML forms cmp-identical - idempotent: re-emitting the KYAML is byte-identical - tools/yaml-comment-proof (#1021): kyaml arm PASS, 26/26 comments preserved, 0 moved, 0 dropped; 8 blank lines lost (cosmetic) - the gates fixed in the previous commits read it correctly (validate-actions-lock, validate-permissions, duplicate keys, governance permissions check, Mustfile pin pattern) Not proven: GitHub's runtime parse of this reusable needs a caller run. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01W5CoaksP2Bg21HpDCgFgwS
Contributor
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 1 minute. View limit detailsLimit details: You’ve used the included review currently available. Review configuration: ⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Advanced Run ID: 📒 Files selected for processing (1)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
hyperpolymath
enabled auto-merge (squash)
October 2, 2026 01:22
Contributor
|
Autopilot could not be updated. Open Coding to check access and billing. |
hyperpolymath
disabled auto-merge
October 2, 2026 01:23
hyperpolymath
enabled auto-merge (squash)
October 2, 2026 01:24
hyperpolymath
disabled auto-merge
October 2, 2026 01:29
hyperpolymath
enabled auto-merge (squash)
October 2, 2026 01:29
hyperpolymath
disabled auto-merge
October 2, 2026 01:30
hyperpolymath
enabled auto-merge (squash)
October 2, 2026 01:30
hyperpolymath
disabled auto-merge
October 2, 2026 01:59
hyperpolymath
enabled auto-merge (squash)
October 2, 2026 02:05
hyperpolymath
disabled auto-merge
October 2, 2026 02:05
3 tasks
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.
Summary
Closes #
Type of change
How has this been verified?
Checklist
git commit -S).SPDX-License-Identifier(code/configMPL-2.0,prose
CC-BY-SA-4.0); I did not relicense existing files.Notes for reviewers