Repository navigation
Fix main: resolve the non-grantable suite's carried policy through the gated entry #6389
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
lukemelia
merged 2 commits into
main
from
cs-13310-realm-policy-non-grantable-test-the-refusal-holds-though-a
Sep 29, 2026
Merged
Changes from all commits
Commits
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
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.
[Claude Code 🤖] In "the refusal holds though a compiled policy carries the grant", the positive control passes whether or not the carried policy reaches the gate, so its message ("the carried policy is the one the gate consults") claims more than it checks. The realm's own compiled policy also grants
annotateonLedger(it compilesrules[1]to['annotate'], as "compiling records a grant of it…" asserts), and it refusessealandupdateon its own. So if the helper'scompiledPolicyoverride stopped reachingloadPolicy, every assertion in that test would still pass. ThesetMottocall throughcarryingin "no grant admits a write a subtype declares for itself" depends on the same override. Under the realm's own policy it is refused for lack of a grant, not by the policy-card rule.A refusal under a carried policy that grants nothing would pin this, because the realm's own policy admits the same call:
The assertion is pre-existing, but this PR is what makes it the suite's positive control again. Non-blocking, and worth doing here.
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.
[Claude Code 🤖] Fixed in
e340990228. The test asserts thatcarrying([], LEDGER_1)('annotate')is refused. The realm's own policy admits that same call, so the assertion fails unless the carried policy reaches the gate. The existing check is relabeled "the carried grant admits annotate".realm-policy-non-grantable-testpasses locally, 18 of 18.