Repository navigation
[spec-review] Update Safe Outputs conformance checker for recent spec changes - #78256
Conversation
There was a problem hiding this comment.
🟡 Changes recommended
TYPE-020 can pass despite a weakened file-count limit or removed duplicate-filename rejection because its text anchors match unrelated code, leaving fail-closed regressions undetected.
2 open issues
What changed in this PR
Updates the Safe Outputs conformance checker to cover specification versions 1.29.22–1.29.26, extending automated checks for recent runtime and compiler safeguards.
Changes:
- Adds checks for branch protection, protected-file merge validation, and authenticated comment selection.
- Adds checks for imported configuration precedence and default issue body operations.
- Updates version metadata without modifying existing checks.
| File | Description |
|---|---|
scripts/check-safe-outputs-conformance.sh |
Adds five conformance checks and updates specification version metadata. |
Review effort: Balanced (dynamic)
| log_high "TYPE-020: protected-files: allowed is not the only configuration that disables the changed-file gate" | ||
| failed=1 | ||
| fi | ||
| if ! echo "$fn" | grep -q '3000'; then |
There was a problem hiding this comment.
Updated TYPE-020 to match the actual pr.changed_files > 3000 guard and added a negative fixture for a weakened limit. Commit: 6556717.
| log_high "TYPE-020: Rename/copy source paths are not included in protected-file evaluation" | ||
| failed=1 | ||
| fi | ||
| if ! echo "$fn" | grep -q 'pr.changed_files' || ! echo "$fn" | grep -q 'new Set'; then |
There was a problem hiding this comment.
Updated TYPE-020 to require the filename-set size and changed-file count comparisons, with a negative fixture that removes duplicate-filename rejection. Commit: 6556717.
|
🍳 A little prep to help this PR along! Copilot assignment requested for the following outstanding work:
Keeping the changes focused; human review and CI get the final taste test. No merging or CI triggering. Structured data{
"completed_task": 0,
"head": "9a69bfafe4b6798235c418aafd041f7ca87ff4c2",
"kind": "requested",
"schema_version": "1",
"state": "0f8a7b0f2c0b90534326185a5b4c95f9fcefc90afa61c2188a9fa6698278f8f4",
"work": [
"1d2f5e13079ab6f75f0c5fb7c482ed3b03a38008bf1f52ed7af32214459b5b77",
"2ef79765c2cab5f2dc222c63f9cf80108e72676d75cf0a29dcf220bed8b7c03d"
],
"workflow": "pr-sous-chef"
}
|
…nce-1-29-26-de1722ca1851eee6 Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Triage
|
|
Category: feature
|
|
🎉 This pull request is included in a new release. Release: |

Summary
This PR updates
scripts/check-safe-outputs-conformance.shto cover Safe Outputs spec versions 1.29.22 through 1.29.26. The script previously covered up to 1.29.21. It adds 5 checks and changes no existing ones. The current code passes every new check, and the script exits with code 0. The 22 MEDIUM and 2 LOW warnings were already present before this change.Specification Changes Reviewed
push_to_pull_request_branchconfirms classic branch protection through GraphQLRef.refUpdateRulemerge_pull_requestblocks protected-file changes by defaultsteerandcreate-pull-requestfields, pluscreate-pull-request.expiresupdate-issueNo steering comments were present on #78251.
📋 Script Updates & Testing Details
New Checks Added
checkBranchPushableinspects active rules, uses GraphQLrefUpdateRuleand never the REST/protectionendpoint. Only an explicitnullallows the push. A missing field or a failed rules or GraphQL query blocks it.evaluateProtectedFilesreusescheckFileProtectionPostApplyand enforces the 3000-file limit. It includes rename sources, rejects incomplete or duplicate file evidence, and runs again during final revalidation. The compiler defaults toblockedand accepts onlyblockedorallowed.createAuthenticatedLoginResolverresolves the login through the handler client and logs the bot fallback.add_commentandcomment_memorycall it only when candidates exist. They matchuser.loginexactly, or fall back touser.type === "Bot", and never usegithub.actor/context.actor.steerremoves the imported value. Importedcreate-pull-requestexpires/draftapply only when the local field is omitted.update-issue.operationis parsed and emitted asdefault_operation, and the schema enum is exactly replace/append/prepend/replace-island. The operation is resolved as agent value, then workflow default, thenappend, and only when the body is enabled and supplied.Header metadata now lists Spec Version 1.29.26.
Checks Modified / Removed
None.
Testing
Negative tests: I temporarily changed
comment_memory.cjsto use a[bot]suffix, and SEC-013 reported CRITICAL. I temporarily changed therefUpdateRuleundefined check inpr_helpers.cjs, and TYPE-019 reported HIGH. Both files were restored.Related Files
docs/src/content/docs/specs/safe-outputs-specification.mdscripts/check-safe-outputs-conformance.shNext Actions