Repository navigation
fix(companions): read continuations and escapes as BuildKit does; list changed paths as they are - #844
Merged
Conversation
…t changed paths as they are Review r96 on #838: - A blank line inside a continuation no longer ends the instruction; BuildKit skips it, so the sources after it are inputs too. - The `# escape=` parser directive names the continuation character (only among the leading directive lines). - The version check lists changed paths with `git diff -z`: git quotes a path with a space or a non-ASCII byte, and the quoted spelling matched no input. - The branch-protection runbook states the live ruleset: Companion version is required since 2026-10-26, added by appending that one context rather than by applying the runbook's payload. Each new test fails on the code before it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Follow-up to #838: the minor findings from review r96.
Change
COPY a \/ blank /b /dst/) no longer ends the instruction. BuildKit skips it, sobis an image input too.# escape=: the parser directive among the leading lines names the continuation character. With# escape=`, a trailing\(a Windows path) is an ordinary character. A directive after the first instruction is an ordinary comment.internal/companionbumplists changed files withgit diff --name-only --no-renames -z. Without-z, git quotesdonnées plugin.pyas"donn\303\251es plugin.py", which matches no input.Companion versionbecame required on 2026-10-26, added with a narrow edit (GET the ruleset, append that one context, PUT it back) rather than the runbook's full payload, which would also flip strict mode, addpnpm source evidenceand droprequire_extra_approval_for_unattributed_changes. A fresh GET after the PUT shows: checksBuild, Proto, Registry cache ×4, Companion version,strict: false,require_extra_approval_for_unattributed_changes: true. Everything else matched the earlier GET.Evidence
Each new test fails on the code before it:
TestAChangedPathIsListedAsItIs: without-zit gets"\"companions/proto/facades/python/donn\\303\\251es plugin.py\"".TestABlankLineInsideAContinuationKeepsTheInstructionandTestTheEscapeDirectiveNamesTheContinuationboth fail against fix(companions): proto 0.0.18 for the streaming facade; refuse an unbumped companion change #838's parser.go test ./companions/ ./internal/companionbump ./internal/ciguardpass. golangci-lint adds no new findings.go run ./internal/companionbump origin/mainpasses: no image input changed.Classification
Fix, in the check #838 added. The scratch-repository git helpers are now shared by the rename test and the new path test.
🤖 Generated with Claude Code