Repository navigation
fix(supabase): sync client options fix from main and make storage list_v2 folder keys optional - #1793
Merged
Merged
Conversation
This was referenced Oct 20, 2026
Contributor
|
The following capabilities are marked
The following capabilities are marked
These may have been renamed, removed, or never registered. Please update the capability matrix. |
grdsdev
reviewed
Oct 20, 2026
grdsdev
left a comment
Contributor
There was a problem hiding this comment.
Review notes. Two findings sit outside the diff, so they are here:
storage_client_timeoutis ignored. Bothreplace()methods accept it, but never use it.ClientOptionshas no such field. A caller that passesreplace(storage_client_timeout=30)gets no error and no change.- The async and sync
replace()are near-identical copies. This fix had to be made twice, and the copies already differ (see therealtimecomment). One shared implementation onClientOptionswould remove the duplication.
spydon
force-pushed
the
v3-sync/03-supabase
branch
2 times, most recently
from
October 21, 2026 07:46
ade67b5 to
e9bb554
Compare
grdsdev
approved these changes
Oct 21, 2026
spydon
force-pushed
the
v3-sync/03-supabase
branch
from
October 22, 2026 07:49
e9bb554 to
6db6288
Compare
spydon
force-pushed
the
v3-sync/03-supabase
branch
from
October 22, 2026 08:01
6db6288 to
3cbd4a1
Compare
spydon
force-pushed
the
v3-sync/03-supabase
branch
from
October 26, 2026 13:45
3cbd4a1 to
1cc493f
Compare
spydon
force-pushed
the
v3-sync/03-supabase
branch
from
October 26, 2026 14:08
1cc493f to
09076cb
Compare
spydon
force-pushed
the
v3-sync/03-supabase
branch
from
October 27, 2026 16:26
09076cb to
b6e224b
Compare
(cherry picked from commit e6fba08)
) Co-authored-by: JSap0914 <[email protected]> Co-authored-by: Leonardo Santiago <[email protected]> (cherry picked from commit 10fb8f9)
Every field now honors falsy values, the sync variant keeps and accepts realtime options, and the unused storage_client_timeout parameter is removed. The replace() tests deleted by the upstream fix are restored.
With storage_client_timeout removed, a positional call could silently set realtime instead. Keyword-only parameters make such calls fail.
spydon
force-pushed
the
v3-sync/03-supabase
branch
from
October 27, 2026 16:48
b6e224b to
dd3aa4f
Compare
spydon
added a commit
that referenced
this pull request
Nov 12, 2026
Step 1 of [SDK-2765](https://linear.app/supabase/issue/SDK-2765) ([SDK-2984](https://linear.app/supabase/issue/SDK-2984)): the typed column expressions and the filter tree that the typed query builder, the realtime bridge and the generator build on. A port of supabase-flutter #1793 with the typed internals of SDK-1753. ## What - `ColumnExpression[Row, Value]` with `Column`, `NullableColumn` and `ComputedField`. `Row` and `Value` are invariant and default to `Any` through `typing_extensions.TypeVar`, so `Column("deleted_at")` works without generated code, while `Books.id.eq("seven")` and a filter from another table are type errors under mypy, pyright and pyrefly without plugins. `Column` and `NullableColumn` are siblings over a private base, so a later `PartialRow.__getitem__` can overload on them without overlapping. - The comparison operators `eq`, `neq`, `gt`, `gte`, `lt`, `lte`, `is_distinct`, `in_`, `text_search(query, type=, config=)` and `raw(operand)`. `is_true()` and `is_false()` take an explicit `self: ColumnExpression[Row, bool]`. `is_null()` exists on `NullableColumn` and `ComputedField` only. - `Filter[Row]`, composed with `&`, `|` and `~`, and `FilterOperator` carrying the wire tokens. `Filter.comparison` exposes a leaf as `Comparison(column, operator, value, negated)`, which is what the realtime bridge will read. `Filter.raw(column, operand)` is the escape hatch for an expression no column can name. - Rendering happens when the request is built, by position: a top-level `&` as separate query parameters, `|` as `or=(…)`, a nested `&` as `and(…)`, a negated leaf in a group as `id.not.eq.2`, a negated group as `not.and=(…)`, and a double negation collapsing. Operands go through the string builder's `sanitize_param` and `_serialize_filter_value`, so the output is the string builder's. `_serialize_filter_value` moves from `request_builder.py` to `utils.py` next to `sanitize_param`, and `_TEXT_SEARCH_OPERATORS` to `types.py`, so the filter module does not depend on the request builder. ## Tests - `test_filter.py` ports the rendering tests of the Dart stack, including the group escaping cases, and asserts for every operator, operand and column name that the query parameters equal what `BaseFilterRequestBuilder` and `SelectRequestBuilder.text_search()` produce. - `test_typecheck.py` runs mypy, pyright and pyrefly on `tests/typecheck/filters.py` and asserts that each reports an error on exactly the lines marked `# error:`: a wrong operand type, a filter from another table, `is_null()` on a `Column` and `is_true()` on a column that is not boolean. mypy and pyright join the `lints` group of the package. The fixture directory is excluded from the package's own pyrefly run. ## Compliance The new symbols are listed under the top-level `supporting_symbols` of `sdk-compliance.yaml`, which covers them without claiming `database.generated_types.typed_queries`. The feature status changes in step 8. Linear: SDK-2984
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.
Cherry-picks main's
supabasepackage change onto v3.function_client_timeoutinreplace()): v3'sClientOptionshas no timeout fields, andreplace()keeps every field throughdataclasses.replace.SearchV2Folder.keyis optional). The latest storage server no longer returnskeyfor folders inlist_v2, so the storage CI job failed on every PR in the stack until this commit lands, and it is moved here to land first.Review fixes
replace()methods go throughdataclasses.replace, so every falsy value (False,{}) is honored and the sync variant keeps and acceptsrealtime.storage_client_timeoutparameter is removed.replace()tests that the upstream commit deleted are restored, with cases for falsy values andrealtime.replace()parameters are keyword-only, so a positional call cannot silently fill the slotstorage_client_timeoutused to have.Commits
keyoptional (fix(storage): make list_v2 method'skeyoptional #1695) (from e6fba08)Stack
This replaces #1789: main's changes since 6f522d3 are cherry-picked onto v3 one package at a time, so each part can be reviewed on its own. Merge from the bottom up.