-
-
Notifications
You must be signed in to change notification settings - Fork 159
fix(ci): ratchet the raw-handle debt baseline across the PR boundary #7825
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,16 @@ | ||
| **The raw-handle debt ratchet now holds across a pull request boundary.** | ||
| CI compared the counted `get_raw_{mut,const}_ptr` sites against | ||
| `scripts/raw_handle_debt_baseline.txt` *from the pull request checkout* — a | ||
| number the same diff was free to move, so adding bare reads and raising the | ||
| baseline (and the per-module ceilings) to match passed the gate. The guarded | ||
| `--update` path refuses to raise, but nothing made CI run it. A new | ||
| `--no-raise-vs <ref>` reads both recorded files out of the merge base and fails | ||
| if the checked-out copies are larger anywhere — the total, an existing module's | ||
| ceiling, or a module absent from the base's list, which is a raise from zero | ||
| rather than a fresh start. Unchanged and lower both pass. Because an unfetched | ||
| merge base makes every file read as absent, and that is indistinguishable from | ||
| "the gate did not exist there", the ref is resolved *before* any file is read | ||
| and an unresolvable one fails the build rather than comparing against nothing; | ||
| the workflow gates the step on `github.event_name == 'pull_request'` rather than | ||
| on an empty variable. `--self-test` grew eight cases covering all three raises, | ||
| four legal diffs, and the unresolvable ref. (#7659, reported in #7389) |
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
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎯 Functional Correctness | 🟠 Major | 🏗️ Heavy lift
Use the actual Git merge base.
Line 263 passes the base branch tip, not
git merge-baseof the pull request head and base. If the base branch advances after the pull request branches, this gate compares against a different revision than the PR objective requires.Fetch both histories with sufficient depth. Compute
git merge-base "$BASE_SHA" "$HEAD_SHA". Pass that SHA to--no-raise-vs. GitHub Actions checks out a pull request merge commit by default and exposes the head SHA separately. (docs.github.com)🤖 Prompt for AI Agents