fix(cli): bump default pg-delta version to pick up PUBLIC-privilege revoke fix - #5970
Merged
Coly010 merged 1 commit intoJul 28, 2026
Conversation
…evoke fix @supabase/pg-delta unconditionally stripped PUBLIC's implicit default privilege from both sides of a privilege diff, silently dropping any REVOKE ... FROM PUBLIC a declarative schema asked for (supabase/pg-toolbelt#308). Fixed upstream in supabase/pg-toolbelt#357, released as @supabase/pg-delta@1.0.0-alpha.33. Fixes #5930
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 0ace9387f3
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Contributor
Supabase CLI previewnpx --yes https://pkg.pr.new/supabase/cli/supabase@0ace9387f3d229870976c8222d0cae0bfc304f95Preview package for commit |
kanadgupta
approved these changes
Jul 28, 2026
Coly010
deleted the
columferry/cli-1947-db-diff-omits-default-privileges-and-function-execute
branch
July 28, 2026 15:08
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.
What changed
supabase db diff(pg-delta engine) silently droppedREVOKE ... FROM PUBLICprivilege changes (default privileges and function EXECUTE) from generated migrations when diffing a declarative schema. Root cause was in the upstream@supabase/pg-deltalibrary:filterPublicBuiltInDefaults()unconditionally stripped PUBLIC's implicit default privilege from both sides of a privilege diff, silently eating anyREVOKE ... FROM PUBLICthe declarative schema asked for.Fixed upstream in supabase/pg-toolbelt#357 (merged), released as
@supabase/pg-delta@1.0.0-alpha.33.This PR:
1.0.0-alpha.32to1.0.0-alpha.33(apps/cli-go/pkg/config/pgdelta_version.go,apps/cli/src/legacy/commands/db/shared/legacy-pgdelta.deno-templates.ts). These are the only version-pin sources of truth — the embedded Deno template scripts always use a fixed placeholder string that gets substituted at runtime, so they're unaffected.apps/cli/src/legacy/commands/db/diff/diff.live.test.ts, a live regression test against a real local Docker stack: a declarative schema revoking a function's implicit PUBLICEXECUTEgrant, diffed withdb diff --local --use-pg-delta, must produce a migration that actually contains theREVOKEstatement. Verified empirically in both directions — passes with thealpha.33pin, and (temporarily reverting toalpha.32) reproduces the silent omission pre-fix.Fixes #5930
Related
Linear: CLI-1947