Repository navigation
feat(cli): upgrade @supabase/typegen to 0.2.2 - #6919
Merged
Merged
Conversation
Takes postgrest-typegen 0.4.0 through the registry. `gen types
typescript` now declares `ComputedFields` next to every table's and
view's `Row`, types named row parameters of functions as
`Omit<Row, ComputedFields>`, and no longer adds a function named like one
of the relation's columns to `Row`. postgrest-js reads `ComputedFields`
to leave computed fields out of `select('*')`.
postgrest-typegen 0.4.0 pins arktype 2.2.5, published inside the
minimumReleaseAge window, so its four packages join the exclusion list
next to the typegen entries.
Contributor
There was a problem hiding this comment.
🤖 AI Review
Both independent reviews reported no findings. Reading the changed files and surrounding code confirmed that the dependency versions, lockfile entries, and release-age exclusions are consistent. No concrete issues found; upstream package behavior was not independently verified.
Findings
No issues found.
Stats
Claude findings: 0 · Codex findings: 0 · Confirmed: 0 · Refuted: 0 · Uncertain: 0
Models: claude-opus-5-5 + gpt-6.1-sol · Trigger: auto · Workflow run
This review runs once per PR. A maintainer can request another with a /ai-review comment.
avallete
approved these changes
Oct 5, 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.
Summary
TL;DR:
gen typesbundles@supabase/typegen@0.2.2, which pins@supabase/postgrest-typegen@0.4.0. TypeScript output gains aComputedFieldskey on every table and view, and functions taking a row through a named parameter are typed without the computed fields. Go, Python, Swift and Dart output are unchanged.Why
postgrest-js leaves computed fields (functions taking the relation's row) out of
select('*'), as PostgREST does, and used to infer whichRowkeys those are fromFunctions. That inference misses named parameters, which the generator has emitted intoRowsince CLI 2.118.0, soselect('*')on such a relation was typed with keys PostgREST never returns. postgrest-typegen 0.4.0 declares them instead (supabase/sdk#243), and postgrest-js reads the declaration in supabase/supabase-js#2730. Design and measurements in SDK-1986.What changed
@supabase/typegenfrom0.2.1to0.2.2inapps/cli/package.json; the lockfile moves@supabase/postgrest-typegenfrom0.3.1to0.4.0andarktypefrom2.2.3to2.2.5(with@ark/schema,@ark/utilandarkregex), which 0.4.0 pins exactly.pnpm-workspace.yaml: theminimumReleaseAgeExcludeentries for the two typegen packages move to the new versions, and the four arktype packages are added. They were published on 2026-09-24 and clear the 7-day window on 2026-10-01, after which their entries can go.Output change for
gen types typescriptA function named like a column of the relation it takes is no longer added to that relation's
Row; the previous output declared the key twice and did not compile. Unnamed row parameters keep the plainRowreference. Older postgrest-js versions ignoreComputedFields.Linked issue
SDK-1986 (Linear). No GitHub issue.
open-for-contributionlabel (or I'm a Supabase maintainer).Checklist
fix(cli): …).pnpm types:checkpasses forapps/cli.gen/typesunit tests: 34 pass,types.layers.unit.test.tsdoes not load locally on my bun (No such built-in module: node:sqlite), unrelated to this change.gen/typesintegration tests: 94 pass.