feat(types): add bigint support for PostgreSQL int8 (64-bit integer)#1044
feat(types): add bigint support for PostgreSQL int8 (64-bit integer)#1044akbarfaa wants to merge 1 commit intosupabase:masterfrom
Conversation
|
No actionable comments were generated in the recent review. 🎉 📝 WalkthroughSummary by CodeRabbit
WalkthroughAdds special handling for PostgreSQL Comment |
|
This PR has been updated and all Docker tests are now green.
|
avallete
left a comment
There was a problem hiding this comment.
There is a lot of changes that seems unrelated to the issue.
Also even tough the types would say so, I'm unsure if postgrest would actually result into a "bigint" when those kind of columns get queried @steve-chavez does it trim the result down to a js "number" or does it returns a "bigint" ?
Also according to docs: unlike Number, BigInt cannot represent decimal values and cannot be mixed with Number in operations without explicit conversion I'm not sure that having both in an union is the solution here. Maybe we can rather have number, or bigint (if postgrest return such values) and feature flag this breaking change on the typegen.
4325bb7 to
b91d026
Compare
We return the bigint but IIRC the we truncate those numbers on the postgrest-js side, see supabase/postgrest-js#319 (comment). |
This PR extends the original change (bigint support in the TypeScript generator) and adds the required fixes to make the Docker test suite green and stable across environments.
What kind of change does this PR introduce?
Feature + test stability fixes:
What is the current behavior?
What is the new behavior?
Tests
Additional context