Repository navigation
test: the rollup catalogs' write side and the definer helpers refuse another role, in both twins (#1341) - #1357
Merged
jdatcmd merged 2 commits intoOct 14, 2026
Conversation
jdatcmd
approved these changes
Oct 14, 2026
jdatcmd
left a comment
Collaborator
There was a problem hiding this comment.
Approving the content at 1e42343. On PG17 I reproduced the write-side claim by giving both catalog policies WITH CHECK (true):
- main: rollup passes 72/72.
- this head: "another role cannot add a group row to the owner's rollup (42501): got [] want [42501]", and the write arm reports
f|2, as you describe.
I agree with your reading of the helpers: require_caller_select checks GetOuterUserId(), so they need arms, not a fix.
Needs a rebase before merge. Main is now 1933577 at 2343 / 1796 (#1353 and #1355 merged). With your six rows (four dated) I expect 2349 / 1798. Rebase and restate from a recount, and I'll check the ledger and merge.
…another role, in both twins (commandprompt#1341) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ommandprompt#1341) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
OffgridwithJD
force-pushed
the
test/1341-rollup-privilege
branch
from
October 14, 2026 01:32
1e42343 to
f90200f
Compare
Collaborator
Author
|
@jdatcmd, rebased onto 1933577. The new head is f90200f, replacing 1e42343. Ledger: 2349 / 1798 (2343 + 6 rows; never 1796 + 2).
|
jdatcmd
approved these changes
Oct 14, 2026
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.
Part of #1341: the three High rollup privilege items (two entries each, from the sql-objects and time-series searches). Every arm is in both twins. Each is red under a mutation of
pgcolumnar--1.0-alpha5.sqlthat main survives.What the code does
Checked in the code before writing any arm:
rollup_source_groupsandrollup_source_retiredare SECURITY DEFINER with PUBLIC EXECUTE, but both first callrequire_caller_select. That checkspg_class_aclcheck(..., GetOuterUserId(), ACL_SELECT), the role outside the definer switch. So this is a missing arm, not a missing fix.Arms and mutations
PG17, both twins, main e848f8f (#1354 merged) against this branch:
PERFORM require_caller_selectdeletedWITH CHECK (true)f|2FOR UPDATEandFOR DELETEpolicyUSING (true)There are two never rows:
In pytest, the write arms come before the existing read-side arms. Its hard asserts stop at the first failure, so a write that gets through is what's reported.
Evidence
--against origin/main(8af86e8) gives rc=0 with the census agreeing; the ceiling stays 246 → 246.🤖 Generated with Claude Code