docs: add a v2 to v3 migration guide - #1660
Conversation
Adds MIGRATION.md at the repository root, modelled on Flame's migration guide: one section per major version step, one subsection per breaking change, each with a before and after snippet. Covers the breaking changes that have landed for v3 so far: the typed RealtimeClient.connectionState, the conn abbreviations spelled out, and the singularized enum names. Linked from both READMEs, and AGENTS.md now states that a breaking change updates the guide in the same pull request.
|
Warning Review limit reached
Next review available in: 4 minutes You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (4)
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 |
Closes SDK-1425
What
v3 is accumulating breaking changes across every package in the monorepo (#1278), and there is nowhere a user can look to find out what they have to change in their own code. The changelogs are per package, auto-generated and one line per commit, so anyone upgrading has to read seven of them and reconstruct the migration themselves.
sdk-compliance.yamltracks capabilities, not migrations.This adds a
MIGRATION.mdat the repository root, modelled on Flame's migration guide:## Migrating from v2 to v3.###subsection per breaking change, titled after what changed.// Before/// AfterDart snippet.One file for the whole monorepo rather than one per package, because the packages go major in lockstep, and it gives us a single link to hand to users.
Covered so far
The two breaking commits that have landed on
main:RealtimeClient.connectionStatechanging fromStringtoSocketState?(refactor(realtime)!: clean up connection naming on RealtimeClient #1404). This is the silent one: the name is unchanged, so anyone comparing it against'open'gets no compile error.connabbreviations spelled out:conn→connection,connState→connectionState,onConnMessage→onConnectionMessage(refactor(realtime)!: clean up connection naming on RealtimeClient #1404).SocketStates→SocketState,PostgresTypes→PostgresType,AuthenticatorAssuranceLevels→AuthenticatorAssuranceLevel,LoadTableSnapshots→TableSnapshotScope.Left out on purpose: the three enums that were never exported (
ChannelStates,ChannelEvents,RealtimeListenTypes) and the enum extensions folded in by #1654, since all of them are@internaland cannot break a consumer.The section carries a note that v3 is unreleased and the list is still growing.
Keeping it current
AGENTS.mdnow states that a change breaking the public API adds its own section toMIGRATION.mdin the same pull request, the same way parity work reconcilessdk-compliance.yaml. There is no pull request template in.github/, so there was nothing to add a checkbox to.Linked from the root
README.mdandpackages/supabase_flutter/README.md, next to the existing Guides and Reference Docs links.Testing
Documentation only, no code changes. Every snippet in the guide was type-checked against the workspace in a scratch file (
dart analyze, clean), which was then deleted.