Repository navigation
ci: check ruff and that _sync is generated from _async - #1866
Merged
Merged
Conversation
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. |
spydon
added a commit
that referenced
this pull request
Oct 28, 2026
## What Make every `implemented` capability in `sdk-compliance.yaml` verifiable by the SDK compliance drift check (see the drift report on #1866). ### Symbols that did not exist - `database.configuration.auto_retry`: `retry` is defined on `AsyncQueryRequestBuilder` / `SyncQueryRequestBuilder` and only inherited by the select builder. The checker matches members where they are defined, not inherited ones. - `realtime.client.disconnect`: the method is `close`, not `disconnect`. - `realtime.subscriptions.subscribe_presence`: there is no `on_presence_change`; the API is `on_presence_sync`, `on_presence_join` and `on_presence_leave`. - `realtime.presence.presence_state`: the method is `presence_state`, not `presences`. - Realtime is async only. `SyncRealtimeClient` and `SyncRealtimeChannel` are stubs without `connect`, `is_connected`, `subscribe`, `unsubscribe`, `send_broadcast`, `on_broadcast`, `on_postgres_changes`, `track` or `untrack`, so those `Sync*` symbols are removed. ### Capabilities without symbols - Filters and modifiers now point at the methods on `BaseFilterRequestBuilder` / `BaseSelectRequestBuilder`, where they are defined. The checker has no `Async`/`Sync` prefix requirement, and the file already used this form for `like_all_of`, `strip_nulls` and `max_affected`. - `regex` and `regex_icase` only work through `filter(column, "match" | "imatch", pattern)`, so they register `filter` and say so in a note. - Features exposed through a parameter of an existing method register that method, for example `insert`/`upsert` for `missing_defaults`, `invoke` for `region_selection`, and `AsyncRealtimeClient.channel` for the channel config options. - `custom_storage` registers `AsyncSupportedStorage` / `SyncSupportedStorage`, and `access_bucket` registers `StorageClient.from_`. - Features that are only constructor options or plain asyncio behaviour (auto refresh, flow type, persist session, custom HTTP client, global headers, heartbeat interval, timeouts and cancellation, cross-client token sync) are marked `no_public_symbols: true`, keeping their existing notes. ## Verification Ran the upstream tooling from `supabase/sdk` at the pinned commit locally: `validate-compliance` passes, and `griffe dump` + `normalize-griffe` + `check-drift` report "No capability matrix drift detected". On `main` the same pipeline reproduces the full drift report from #1866.
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.
Stacked on #1865, which formats the files these checks would otherwise fail on and restores the
_asyncdocstring that #1569 only added to_sync. Merge that one first.Summary
CI only runs
make <pkg>.tests(mypy and pytest), so nothing checks lint, formatting, or whether the generated_synccode matches its_asyncsource. #1569 is an example: it edited_sync/gotrue_client.pydirectly, and the nextmake auth.build-syncwould have silently deleted that change.This adds a
lintjob with three steps, using the ruff version locked inuv.lock:ruff check --output-format=github, so violations show as inline annotations on the PRruff format --check_syncwith the new rootmake build-synctarget, run ruff, and fail if anything undersrc/changed or was added, printing the diffThe root
build-synctarget runsbuild-syncfor every package that has one (functions,storage,auth,postgrest,supabase;realtimeis async only), so contributors can run the same thing locally.The job runs in parallel with the test matrix and does not gate
release-please.Verification
Locally, the sync check passes on this branch and fails when the
_asyncdocstring from #1865 is reverted, reportingsrc/auth/src/supabase_auth/_sync/gotrue_client.py.