Repository navigation
chore: register the remaining public API in the capability matrix - #1673
Conversation
The capability matrix extractor treats every non-underscore name in lib/ as public API, without following exports. Plenty of implementation plumbing in lib/src/ therefore counted as public surface that had to be either registered in sdk-compliance.yaml or left as an unexplained gap. @internal is the marker the extractor already honours for exactly this case, and the repo already uses it on members; this extends it to the declarations themselves. Annotates 24 declarations that are public by Dart's underscore rule but are not reachable from their package's public library: HTTP plumbing (GotrueFetch, Fetch, AuthHttpClient, GotrueRequestOptions, RequestMethodType, ApiVersion), realtime transport internals (Push, Hook, Message, Serializer, RetryTimer and their typedefs), per-package Constants, and a few helpers (Counter, ToQueryParams, SupabaseAuth, the admin OAuth client response wrappers). Deliberately excluded: anything with symbols registered in sdk-compliance.yaml as capability evidence, since annotating those would hide them from the extractor and break the drift check. That ruled out StorageBucketApi, GoTrueAdminOAuthApi, GoTrueAdminCustomProvidersApi, GoTrueAdminMFAApi, realtime's Constants and ChannelFilter. Also excluded File and YAJsonIsolate, which are reachable publicly via conditional imports and exports. functions_client gains a meta dependency, which it did not previously have. Reported public surface drops from 1952 symbols to 1831.
Brings capability-matrix coverage of the Dart public API from 49% to 100%. The 881 unregistered symbols split three ways: - 500 are attributed to the capability they support, and 26 are entry points the matrix was missing outright (GoTrueClient.updateUser, SupabaseClient.from, RealtimeChannel.onPostgresChanges, StorageFileApi.createSignedUrl, ...). - 355 go in the top-level supporting_symbols list: shared domain models, the exception hierarchies, the client handles that gate whole areas, and surface the canonical registry has no id for. - 26 are not public API at all and leave the scan instead of entering the matrix. #1671's script only matched class-like declarations, so top-level functions and variables were missed: the realtime transformers, the conditional-import platform shims, and the passkey option mappers are now @internal. ChannelFilter joins them; it is hidden from realtime_client's public library, so it could not serve as evidence for postgres changes, and RealtimeChannel.onPostgresChanges replaces it there. Two paths cannot carry the annotation and are excluded by .sdk-parse-ignore instead: each package's own example app, which the extractor treats as a package because it has a pubspec.yaml, and version.dart, which the release tooling rewrites wholesale. Also declares storage.errors.error_codes, which StorageException.error already implements.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthroughThe PR marks implementation APIs as internal, narrows a realtime transformer export, adds an explicit ChangesSDK surface and compliance coverage
Estimated code review effort: 3 (Moderate) | ~20 minutes Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Pull request overview
This PR completes the backfill of the capability matrix (sdk-compliance.yaml) so that the Dart SDK’s extracted public API symbols are fully accounted for, and it tightens a small amount of accidentally-exported surface by marking helper declarations @internal and narrowing exports.
Changes:
- Expanded
sdk-compliance.yamlto register the remaining public API symbols (including missing entry points and supporting types) and added a newstorage.errors.error_codesfeature. - Marked various top-level helpers / shims as
@internalso they no longer count as SDK public API symbols. - Narrowed
realtime_clientexports oftransformers.dartfromhide ...toshow PostgresColumn, PostgresTypeto prevent future accidental leakage.
Reviewed changes
Copilot reviewed 17 out of 17 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| sdk-compliance.yaml | Registers remaining public API symbols into capability matrix features/supporting symbols. |
| packages/supabase_flutter/lib/src/passkey/passkey_options_mapper.dart | Marks passkey options mapping helpers @internal. |
| packages/supabase_flutter/lib/src/local_storage_web.dart | Marks web local storage helpers @internal. |
| packages/supabase_flutter/lib/src/local_storage_stub.dart | Marks stub local storage helpers @internal. |
| packages/supabase_flutter/lib/src/hot_restart_cleanup_web.dart | Marks hot-restart cleanup hooks @internal for web. |
| packages/supabase_flutter/lib/src/hot_restart_cleanup_stub.dart | Marks hot-restart cleanup hooks @internal for stub. |
| packages/realtime_client/lib/src/websocket/websocket_web.dart | Marks createWebSocketClient @internal for web implementation. |
| packages/realtime_client/lib/src/websocket/websocket_stub.dart | Marks createWebSocketClient @internal for stub implementation. |
| packages/realtime_client/lib/src/websocket/websocket_io.dart | Marks createWebSocketClient @internal for IO implementation. |
| packages/realtime_client/lib/src/types.dart | Marks ChannelFilter @internal (no longer treated as SDK public API evidence). |
| packages/realtime_client/lib/src/transformers.dart | Marks transformer helpers @internal (keeps only intended public types). |
| packages/realtime_client/lib/src/retry_timer.dart | Marks maxShift @internal. |
| packages/realtime_client/lib/realtime_client.dart | Narrows exports of transformers to only PostgresColumn and PostgresType. |
| packages/postgrest/lib/src/constants.dart | Marks defaultHeaders @internal. |
| packages/gotrue/lib/src/broadcast_web.dart | Marks getBroadcastChannel @internal for web implementation. |
| packages/gotrue/lib/src/broadcast_stub.dart | Marks getBroadcastChannel @internal for stub implementation. |
| .sdk-parse-ignore | Excludes per-package examples and rewritten version.dart from API extraction. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Stacked on #1673. Follow-up to the audit in that PR: of the 536 entries in the top-level `supporting_symbols` list, ten were realtime transport internals that had no business being public in the first place. They were registered there for want of a better home, which was the wrong answer. ## What becomes `@internal` | Symbol | What it is | |---|---| | `RealtimeClient.sendBuffer` | Queue of callbacks awaiting a connection | | `RealtimeClient.stateChangeCallbacks` | The `open`/`close`/`error`/`message` listener registry behind `onOpen` and friends | | `RealtimeClient.ref` | Message ref counter | | `RealtimeClient.makeRef` | Increments the counter, handling overflow | | `RealtimeClient.push` | Raw frame send | | `RealtimeClient.heartbeatTimer` | The `Timer` driving heartbeats | | `RealtimeClient.pendingHeartbeatRef` | Ref of the last unacknowledged heartbeat | | `RealtimeClient.reconnectTimer` | The `RetryTimer` behind reconnect backoff | | `RealtimeChannel.canPush` | Whether the socket is connected and the channel joined | | `RealtimeChannel.trigger` | Dispatches a raw event to the channel's bindings | `push` is the clearest case: it already took `Message`, which #1671 marked `@internal`, so it could not be called from outside the package regardless. Its signature said internal while its name said public. The rest are fields on a class that happens to be public, so Dart's underscore rule made them public by default. None appears in any documented flow. Every one of them has a public counterpart that is the supported way in: `onOpen`/`onClose`/`onError`/`onMessage` instead of `stateChangeCallbacks`, `heartbeatIntervalMs` instead of `heartbeatTimer`, `reconnectAfterMs` instead of `reconnectTimer`, `sendBroadcastMessage` instead of `push`. ## Matrix changes Ten symbols leave the scan, so they leave `sdk-compliance.yaml` too: - Eight drop out of the top-level `supporting_symbols` list. - `RealtimeClient.reconnectTimer` drops from `realtime.configuration.reconnect_backoff`, and `heartbeatTimer`/`pendingHeartbeatRef` from `realtime.configuration.heartbeat_interval`. Both features keep their real evidence (`reconnectAfterMs`, `heartbeatIntervalMs`), and `reconnect_backoff` no longer needs a `supporting_symbols` list at all. Public surface 1774 → 1764. Coverage stays at 100%. ## Breaking Marked `chore(realtime)!` with a `BREAKING CHANGE` footer. It is a genuine public API removal, though the practical risk is low: none of these is documented, `push` was already uncallable, and v3 is the right window. Anyone reaching for them was working around a missing public API, which is worth an issue rather than a lint suppression. ## Test plan - [x] `dart analyze packages/`: **No issues found.** This is the gate that matters here: `invalid_use_of_internal_member` fires for any cross-package use, and the `supabase` and `supabase_flutter` packages both consume `RealtimeClient` and `RealtimeChannel`. Neither touches any of the ten. - [x] `realtime_client` tests: 205 passed. `@internal` permits same-package use, so the existing tests that drive `makeRef`, `push` and `trigger` still compile and run. - [x] `supabase` tests: 134 passed, including the realtime stream integration tests. - [x] `supabase_flutter` tests: 65 passed. - [x] `check-drift`: `✅ No capability matrix drift detected.` - [x] `check-api-symbols` against #1673 as base: `✅ All new public API symbols are covered in the capability matrix.` This is the check that would have caught a stale registration, since the ten removed symbols were all registered on the base. - [x] Uncovered symbol count from a fresh extraction: **0**. - [x] `dart format packages/`: 0 changed.
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@sdk-compliance.yaml`:
- Around line 1654-1659: Qualify every affected Constants reference in
sdk-compliance.yaml, including the entries around the listed sections, with its
owning package context so registry matching cannot resolve the wrong Constants
class. Preserve the referenced members such as defaultConnectionCloseTimeout and
wsCloseNormal while applying the correct package qualification for
functions_client, gotrue, realtime_client, storage_client, supabase, and
supabase_flutter.
🪄 Autofix
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: b6855024-e122-4ddb-a4fd-7fab08b4f8f2
📒 Files selected for processing (19)
.sdk-parse-ignorepackages/gotrue/lib/src/broadcast_stub.dartpackages/gotrue/lib/src/broadcast_web.dartpackages/postgrest/lib/src/constants.dartpackages/realtime_client/lib/realtime_client.dartpackages/realtime_client/lib/src/realtime_channel.dartpackages/realtime_client/lib/src/realtime_client.dartpackages/realtime_client/lib/src/retry_timer.dartpackages/realtime_client/lib/src/transformers.dartpackages/realtime_client/lib/src/types.dartpackages/realtime_client/lib/src/websocket/websocket_io.dartpackages/realtime_client/lib/src/websocket/websocket_stub.dartpackages/realtime_client/lib/src/websocket/websocket_web.dartpackages/supabase_flutter/lib/src/hot_restart_cleanup_stub.dartpackages/supabase_flutter/lib/src/hot_restart_cleanup_web.dartpackages/supabase_flutter/lib/src/local_storage_stub.dartpackages/supabase_flutter/lib/src/local_storage_web.dartpackages/supabase_flutter/lib/src/passkey/passkey_options_mapper.dartsdk-compliance.yaml
The annotation was dropped while resolving the merge conflict in 1f29193.
The shared HttpMethod enum moves into supabase_common (#1678), which the public API scan excludes, so registering it here would leave a dangling entry once that lands. FunctionsClient.invoke is the entry point a caller actually reaches for anyway.
## Why Four different representations of an HTTP method coexisted across the packages: | Package | Representation | Values | Wire string | |---|---|---|---| | `functions_client` | public `enum HttpMethod` | get, post, put, delete, patch | `method.name.toUpperCase()`, open-coded at two call sites | | `postgrest` | public `enum HttpMethod` | get, **head**, post, put, patch, delete | `String get value => name.toUpperCase()` | | `gotrue` | `@internal enum RequestMethodType` | get, post, put, patch, delete | none, switches to `http.Client`'s `get` / `post` / … | | `storage_client` | bare `String` | `'GET'`, `'POST'`, `'PUT'`, `'DELETE'`, `'HEAD'` | the literal itself | The two public enums shared a name while disagreeing on contents, which forced `supabase.dart` to export postgrest with `hide HttpMethod`, making postgrest's enum unreachable through the umbrella library. It also confused the capability matrix, which keys symbols by bare name: it registered `HttpMethod` for functions and `HttpMethod.value` for postgrest as if they were one type. The stringly-typed side had its own cost. `storage_client` compared `method != 'GET'` to decide whether to set a JSON content type, in both its `Fetch` helper and its Iceberg REST catalog. ## What changed One `HttpMethod` in `supabase_common`, taking postgrest's shape: the six methods plus the `value` getter that `functions_client` used to open-code. Public surface: - `functions_client` and `postgrest` re-export the shared enum, so callers of either library see no change. - `supabase.dart` exports postgrest whole again. - `functions.invocation.method_override` registers `FunctionsClient.invoke`, since the shared enum lives in `supabase_common`, which `.sdk-parse-ignore` excludes from the scanned public API surface. A note records that the Dart enum also offers `head`, which supabase-js does not expose for function invocation. - The `edge_functions` example's "every HTTP method" test skips `head`, whose response carries no body for the echo function to reflect, and asserts against `method.value`. Internal adoption, no public API change since both declarations were `@internal`: - `gotrue`: `RequestMethodType` is gone and its roughly 65 call sites use the shared enum. `GotrueFetch`'s dispatch switch gains a `head` branch to stay exhaustive over six values, wired to `http.Client.head`, and now skips the JSON content type for `head` as well as for `get`. No gotrue call site issues a HEAD today, so that branch is currently unexercised. - `storage_client`: `Fetch`'s private request helpers and the Iceberg catalog's `_request` take an `HttpMethod` instead of a `String`, the wire strings come from `.value`, and the content-type branch compares enum values. The public wrapper method names (`get`, `post`, `head`, and so on) are unchanged. Every log line that interpolates a method uses `.value`, so they keep printing `GET` rather than the enum's default `toString`. The `supabase_common` pins stay at `0.1.2`; `melos version` rewrites dependents' pins at release time. ## Merge order This targets `main` directly and does not depend on #1673 or #1677, though it came out of the same review thread. #1673 previously registered `HttpMethod` and `HttpMethod.value`, which this PR makes dangling; those registrations have been pruned on that branch, so the two can merge in either order. ## Verification - `dart analyze` clean across all packages and examples. - `dcm analyze` reports no issues in any file this PR touches. - Suites pass against a local Supabase stack, at the `--concurrency=1` the workflow uses: `gotrue` (479), `storage_client` (210), `postgrest` (196), `functions_client` (48). - The compliance symbol, drift and schema checks pass locally with `main` as the base. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Added a shared `HttpMethod` API covering GET, HEAD, POST, PUT, PATCH, and DELETE. - Made `HttpMethod` available through the relevant client libraries. - Added explicit HEAD request support where applicable. - **Bug Fixes** - Improved HTTP method serialization for requests. - Corrected request content handling for GET and HEAD calls. - Updated integration coverage to accurately validate supported methods. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
Adds six capability ids across two areas, plus one new group. These came out of backfilling supabase-flutter's `sdk-compliance.yaml` against its full public API ([supabase-flutter#1673](supabase/supabase-flutter#1673)). Reaching 100% coverage meant every public symbol needed a home, which made it obvious which operations the registry has no id for. Each one below is a gap in the registry's own symmetry rather than a Dart-shaped request: in every case a sibling area already has the equivalent capability. ## `storage.analytics.access_catalog` `storage.file_buckets.access_bucket` ("Scope subsequent file operations to a specific bucket") and `storage.vector_buckets.access_vector_index` ("Scope subsequent vector operations to a specific index within a bucket") both exist. Analytics has seventeen operations across namespaces and tables, and no id for the handle you need before you can call any of them. Worth noting the asymmetry is recent: #74 and #76 filled in the analytics operations without adding the accessor the other two groups have. ## `auth.passkey.list_passkeys`, `update_passkey`, `delete_passkey` `auth.passkey_admin.list_passkeys` and `auth.passkey_admin.delete_passkey` already cover an admin enumerating and revoking a user's passkeys. There was nothing for a user managing their own credentials, which is the more common flow of the two, and no id at all for renaming one. `update_passkey` is described narrowly (mutable metadata, such as the friendly name) since the credential itself is immutable. ## `storage.file_buckets.request_cancellation` and `storage.configuration.auto_retry` `database.using_modifiers.request_cancellation` and `functions.invocation.request_cancellation` both exist, as does `database.configuration.auto_retry`. Storage was the one area with retry and abort behaviour and no id for either, which is arguably backwards: aborting a multi-megabyte upload is more user-visible than aborting a query. `auto_retry` needs a new `configuration` group in the storage area, matching the group of the same name in database. ## What I deliberately left out Four gaps surfaced in the same audit that I do **not** think belong here: - **Client disposal** (`Supabase.instance.dispose`). This started out in the PR as `client.lifecycle.dispose` and has been dropped following [review](#78 (comment)). Two reasons. First, the id was not adjudicable: it needed an escape hatch so garbage-collected runtimes could declare `not_applicable`, but process termination releases resources on every runtime, so there was no observable test separating "reclaims automatically" from "implemented". Second, the teardown surface a caller can actually see is already registered, via `realtime.client.disconnect`, `realtime.client.remove_all_channels` and `realtime.channel.unsubscribe`. A whole-client `dispose` is largely the aggregate of those plus internal timers and connection pooling, so its presence or absence says little about parity that the existing ids do not already say. Releasing resources idiomatically is a baseline every SDK owes its framework rather than a feature it can lack. - **Client construction** (`Supabase.initialize`, `instance`, `isInitialized`). Every SDK has it, but it is the precondition for the whole matrix rather than a feature within it. - **Table streams as a database capability** (`SupabaseQueryBuilder.stream`). This one is a genuine inconsistency, but possibly on the Dart side. The registry already carries the *modifiers* of this capability, since supabase-flutter registers `SupabaseStreamFilterBuilder.eq` under `database.using_filters.eq` and `SupabaseStreamBuilder.order` under `database.using_modifiers.order`, yet there is no id for the operation those modify. supabase-js has no direct equivalent (you compose a channel with postgres changes by hand), so this may be Dart sugar that should be attributed differently rather than a missing id. Raising it as a question rather than proposing an id. - **Typed row mapping** (`withConverter`). The Dart idiom for what TypeScript does with generics, so not a cross-SDK capability. ## Compliance impact None of these is breaking. No id is renamed and no existing entry changes, so every SDK's `sdk-compliance.yaml` keeps validating; the six new ids simply default to `not_implemented` until an SDK declares them. supabase-flutter implements all six and will declare them in a follow-up, which moves the corresponding symbols out of its generic top-level `supporting_symbols` list into the features they actually belong to. Its disposal symbols stay in `supporting_symbols`, which is where they already are today. ## Test plan - [x] `npm run validate`: `OK — capability matrix is valid.` - [x] `npm test`: 195 passed across 14 files. - [x] `npm run typecheck`: clean. - [x] Confirmed against `capabilities/*.yaml` that none of the six ids already exists under another name, and that the new `storage.configuration` group is new. - [x] Confirmed `capabilities/client.yaml` is byte-identical to `main` after dropping the disposal id.
…1677) Stacked on #1673, addressing #1673 (comment). ## Why Six packages declared a class named `Constants`: `functions_client`, `gotrue`, `realtime_client`, `storage_client`, `supabase` and `supabase_flutter`. The capability matrix keys symbols by bare name, so an entry like `Constants.defaultHeaders` could not say which package it meant. The same ambiguity applies to anyone reading the code across packages. ## What changed Each class is named after its package, and the file declaring it is named to match: | Package | Class | File | |---|---|---| | `functions_client` | `FunctionsConstants` | `src/functions_constants.dart` | | `gotrue` | `GoTrueConstants` | `src/gotrue_constants.dart` | | `realtime_client` | `RealtimeConstants` | `src/realtime_constants.dart` | | `storage_client` | `StorageConstants` | `src/storage_constants.dart` | | `supabase` | `SupabaseConstants` | `src/supabase_constants.dart` | | `supabase_flutter` | `SupabaseFlutterConstants` | `src/supabase_flutter_constants.dart` | `gotrue` and `realtime_client` keep a `constants.dart`, since both also declare enums there. Only the class moved out into its own file, so `constants.dart` now holds exactly the enums and, for `gotrue`, `ApiVersions`. `gotrue.dart` no longer needs `hide Constants` on its export as a result. `realtime_client` holds the only public class of the six, so it changed the most: - The `typedef RealtimeConstants = Constants` is gone and the class carries that name directly. `realtime_client.dart` only ever exported the alias, so the name consumers write is unchanged. - `defaultHeaders`, `defaultHeartbeatIntervalMs` and `wsCloseNormal` are now `@internal`. Nothing outside the package reads them, and the other five packages' default header maps were already internal. This is the breaking part: code outside the package that reached for them will now get `invalid_use_of_internal_member`. - `defaultTimeout` and `defaultConnectionCloseTimeout` stay public, because `supabase` reads both when filling in unset `RealtimeClientOptions`. In `sdk-compliance.yaml`, the three now-internal symbols are dropped, `realtime.configuration.heartbeat_interval` loses its `supporting_symbols` list along with them, the duplicated `Constants` and `Constants.defaultTimeout` pair is removed from the top-level list, and `RealtimeConstants.defaultConnectionCloseTimeout` and `RealtimeConstants.defaultTimeout` are registered under the new name. ## Verification - `dart analyze` clean across all packages and examples. - Full suites pass against a local Supabase stack, at the `--concurrency=1` the workflow uses: `gotrue` (479), `realtime_client` (205, integration included), `storage_client` (210), `supabase` (134), `supabase_flutter` (65), `functions_client` (48). - The compliance symbol, drift and schema checks pass locally against this branch's base. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Realtime configuration constants are now available through the public library interface. * **Refactor** * Standardized configuration naming across authentication, database, functions, realtime, storage, and Flutter integrations. * Centralized default headers, timeouts, session settings, and client metadata under clearer service-specific constants. * Preserved existing defaults and runtime behavior. * **Tests** * Updated automated coverage to validate the renamed configuration references and existing expected values. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
Stacked on #1671. Closes the backfill that #1670 and #1671 flagged: capability-matrix coverage of the Dart public API goes from 49% to 100%.
How the 881 unregistered symbols were placed
26 are entry points the matrix was missing outright. These go in
symbols, so the drift check now verifies them:auth.session.update_userGoTrueClient.updateUserauth.session.get_session/get_userGoTrueClient.currentSession/currentUserauth.sign_in.sign_in_with_oauthGoTrueClient.getOAuthSignInUrl,GoTrueClientSignInProvider.signInWithOAuthauth.sign_in.sign_in_with_ssoGoTrueClientSignInProvider.signInWithSSOauth.identities.link_identityGoTrueClientSignInProvider.linkIdentityauth.passkey.*GoTruePasskeyApi.start/verifyRegistration,start/verifyAuthenticationdatabase.query.from_table/rpc/schema_selectionSupabaseClient.from/rpc/schemadatabase.using_modifiers.explainPostgrestTransformBuilder.explainrealtime.subscriptions.postgres_changesRealtimeChannel.onPostgresChanges,onSystemEventsrealtime.client.*SupabaseClient.channel,getChannels,removeChannel,removeAllChannels,RealtimeClient.disconnectstorage.file_buckets.create_signed_urlStorageFileApi.createSignedUrlclient.*GoTrueClient.getSessionFromUrl,recoverSession,setInitialSessionSeveral of these features previously listed only an option or enum as their evidence.
storage.file_buckets.create_signed_urlclaimedDownloadBehavior;database.using_modifiers.explainclaimedExplainFormat;auth.session.update_userclaimedUserAttributes.currentPassword. The method that actually implements the capability was unregistered in each case.500 go in a feature's
supporting_symbols, where the type maps onto one capability: the MFA response types to their operations,Jwt*/JWK*/DecodedJwttoget_claims,FileObjectV2tofile_info,SignedUrl*tocreate_signed_urls, the presence payloads tosubscribe_presence, and so on.355 go in the top-level
supporting_symbolslist. Four kinds:Session,User,AuthResponse,Bucket,OAuthClient,Factor. Accepted or returned by many features at once, so no single feature id is a truthful home.AuthException,PostgrestException,FunctionException,RealtimeSubscribeExceptionand subclasses. Thrown rather than passed, so reachable from no signature.SupabaseClient,GoTrueClient,RealtimeClient,GoTrueAdminApiand the accessors returning them gate whole areas; their operations are attributed individually.26 symbols left the scan instead of entering the matrix
#1671's script only matched class-like declarations, so top-level functions and variables slipped through. Now
@internal:realtime_client/src/transformers.dart:convertCell,convertColumn,convertChangeData,toArray,toBoolean,toDouble,toInt,toJson,toTimestampString,noop,httpEndpointURL,getEnrichedPayload,getPayloadRecordsaccessToken,hasAccessToken,persistSession,removePersistedSession,disposePreviousClient,markClientToDispose,supabaseFlutterClientToDispose,getBroadcastChannel,createWebSocketClientpasskeyRegisterRequestFromOptions,passkeyAuthenticateRequestFromOptions,maxShift,defaultHeadersChannelFilterjoins them, and this one is worth a second look: it is hidden fromrealtime_client's public library, soChannelFilter.selectcould never have been drift-verified evidence forrealtime.subscriptions.postgres_changes.RealtimeChannel.onPostgresChangesreplaces it.Two paths cannot carry the annotation, so
.sdk-parse-ignoreexcludes them:packages/*/example/— each package ships its own example app, and the extractor treats it as a package of its own because it has apubspec.yaml.MyApp,MyWidgetandmainwere counted as SDK public API.examples/was already excluded for exactly this reason.packages/*/lib/src/version.dart— the release tooling rewrites it wholesale (echo "const version = '$version';" > ...), so an annotation would not survive a release.One behaviour-visible change
realtime_client.dartchanges fromexport 'src/transformers.dart' hide getEnrichedPayload, getPayloadRecordstoshow PostgresColumn, PostgresType. The 13 payload-conversion helpers above were public only by accident of that hide list, and the analyzer requires it:@internalon an exported member isinvalid_export_of_internal_element. Theshowform also stops the next helper added to that file from leaking.This removes public API. It is not API anyone should be calling (
toInt,noop,convertCell), and v3 is already removing dead public surface, but it is the one item here that is not purely additive.Also declared:
storage.errors.error_codesThe validator reported it undeclared, and
StorageException.erroralready carries the machine-readable service code the capability describes. Declared as implemented, which also givesStorageExceptiona real home instead of the shared bucket.Gaps this surfaced
Public API with no canonical capability id, currently parked in the top-level list. Each is a candidate for a new id in
supabase/sdk:Supabase.initialize,Supabase.instance,Supabase.client,isInitialized, anddisposeon every client.client.*has no lifecycle group at all.GoTruePasskeyApi.list,delete,update. The matrix hasauth.passkey_admin.list_passkeysanddelete_passkeyfor the admin API, but nothing for a user managing their own.SupabaseQueryBuilder.streamandSupabaseStreamBuilder. The stream filters and modifiers are registered underdatabase.using_filters.*andusing_modifiers.*, butstream()itself is not a capability.StorageClientOptions.retryAttemptsandStorageRetryController.database.configuration.auto_retryexists; there is no storage equivalent.realtime.subscriptions.postgres_changes_multiple_filtersis the one remaining undeclared feature, and Dart implements it (onPostgresChanges(filters: [...])). Declaring it needsRealtimeChannel.onPostgresChangesregistered against two features, so it is left out here rather than adding a duplicate registration.Two more judgement calls worth flagging:
RealtimeClientexposes transport internals —sendBuffer,stateChangeCallbacks,pendingHeartbeatRef,makeRef,ref,push,heartbeatTimer,reconnectTimer, andRealtimeChannel.canPush/trigger. Registered here because they are genuinely exported, but they read like@internalcandidates for a future breaking change.yet_another_json_isolatecontributes 13 symbols with no Supabase capability behind them. Registered in the top-level list; it could instead be excluded from the scan the waysupabase_commonis.Test plan
dart analyze packages/: No issues found. This is the real gate forinvalid_internal_annotation,invalid_use_of_internal_memberandinvalid_export_of_internal_element.OK — compliance file is valid.check-drift:✅ No capability matrix drift detected.check-api-symbolsagainst chore: mark non-public declarations @internal #1671 as base:✅ All new public API symbols are covered in the capability matrix.Nothing registered was removed, and nothing new is uncovered.StorageFileApi.moveformoveandmove_cross_bucket). This change adds none.dart format packages/: 0 changed.gotrue471,realtime_client205,postgrest196,supabase134,storage_client210,supabase_flutter65,functions_client48.postgrestneeds-j 1; run in parallel its test files race on the shared database reset helper, which varies the failure count run to run on unmodified code.Summary by CodeRabbit
API Improvements
Compatibility
Bug Fixes