Repository navigation
docs(ai-migration): make the v9 β v10 guide agent-ready and re-verify against V10 - #3918
Merged
Merged
Conversation
β¦ against V10 Restructure ai-docs/ai-migration-v9-to-v10.md for coding agents: rules, companion documents, a phased workflow with a definition of done and a report template, root-agnostic detection, a consolidated table of breaks that still compile, and verification with a leftover-identifier grep at the end. Duplicate ids are resolved (i18n is Part S, Verify is unnumbered), K.x is in order, and every Β§ reference resolves. Re-verify against V10 HEAD: cover #3916's reopen-at-latest default and useJumpToLatestOnOpen, correct the statusReporter, useMutedUsers, typing and DEFAULT_BACKEND_SORT claims, and drop names that only existed in release candidates. Sections with no integrator action shrink to one line, with their detail moved to v10-breaking-changes.md. The v8 β v9 guide now points at this one.
client.moderation.flagMessage and flagUser take an object
({ message_id } / { user_id }), not a positional id.
isekovanic
approved these changes
Nov 3, 2026
oliverlaz
added a commit
to GetStream/stream-chat-js
that referenced
this pull request
Nov 3, 2026
β¦reaking changes at HEAD (#1984) Ticket: https://linear.app/stream/issue/REACT-1307 ## Goal Make the v9 β v10 migration docs usable as the input of a prebuilt migration prompt: a coding agent gets one URL plus the user's repo, and has to migrate accurately. Until now `stream-chat` had only the exhaustive audit (`v10-breaking-changes.md`), and no execution guide. ## Changes **New `ai-docs/ai-migration-v9-to-v10.md`** (entry guide, ~1.2k lines) - Rules for the agent: the installed `node_modules/stream-chat` is the source of truth, verify before writing, stop on a missing symbol, smallest edit, a green build is not done. - Companion documents, a phased workflow (preflight β install β detect β apply β silent breaks β verify β report), a definition of done and a report template. - Detection greps keyed on v9 names that search the whole repo, not just `src/`. - A quick reference of about 125 v9 β v10 rows, each linked to a reference anchor. - Inline before/after snippets for the high-impact changes. All 25 v10 snippets compile with `tsc --strict` against `src/`. - Breaks that compile, each with a Detect command. - A leftover-identifier grep covering removed methods and events and all 376 removed type names. - An index that maps all 243 reference anchors to guide sections or "reference only". - Server-side code (secret, token signing, webhooks, admin endpoints) is detected and routed to `@stream-io/node-sdk`, not ported onto `stream-chat`. **`ai-docs/v10-breaking-changes.md`, re-verified at `fdfcb296` (rc.30)** - New break: the #1969 regen dropped `call_level` from `PushPreferenceInput` / `PushPreferencesResponse`. It also re-exported `BlocklistBehavior` and `ModerationAction`, which the rename table listed as removed. - Read events after #1981: - The `read-events` capability is checked via `channel.readEventsEnabled`. - The reporter path resolves `null` instead of throwing. - Only a direct `markRead()` / `markUnread()` throws. - Other entries updated to HEAD behaviour: - mark-read throttling is per channel/thread; - recovery re-queries loaded pages; - network-failed messages get `status: 0`; - thread participants are merged; - joined/invite filters and `addFilterResolvers`; - watcher, ban and member-removal events; - `user.updated` reaches threads; - the composer restores `custom` from drafts and edits. - **No anchor renamed or removed.** The React and RN guides link to them. One anchor was added: `composer-custom-data-restore`. ## How it was checked - Every identifier on the "after" side was checked mechanically to exist in `src/`; the only misses are v9 names, placeholders and prose. - The detection and verification greps were run against a v9 fixture app. - `prettier --check` passes. ## Open questions for review - For channels, should `updatePartial` set custom fields as `'custom.name'` dot paths or as flat keys? React's `ChannelManagementView` uses dot paths, while the docs-snippet test uses flat keys. - The reference still has a few notes for rc users (`ensureWatched`, renamed paginator members). The guide has none. Keep them or drop them? ## Related PRs The three guides link to each other; review together: - stream-chat-js: #1984 (merge first: the React and RN guides link to its raw URL) - stream-chat-react: GetStream/stream-chat-react#3377 - stream-chat-react-native: GetStream/stream-chat-react-native#3918
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.
Ticket: https://linear.app/stream/issue/REACT-1307
Goal
Make the v9 β v10 guide the input of a prebuilt migration prompt: a coding agent gets one URL plus the user's repo and has to migrate accurately. The guide had grown by accretion, which hurt that:
src/;Changes
ai-docs/ai-migration-v9-to-v10.md: structurerg -t js -t ts -g '!**/node_modules/**', keyed on v9 names)v10-breaking-changes.mdsection to a guide section## Verification, so every existingΒ§19reference (all of them mean i18n) stays valid.ai-docs/resolves to a unique heading.v10-breaking-changes.md.Accuracy, re-verified at
74884ff55useJumpToLatestOnOpenis exported. Covered in Β§8, Β§R.5, the breaks table and the reference.<Chat>does not replace an app'sstatusReporter; the app's reporter wins (Β§R.2).useMutedUsers()returnsUserMuteResponse[];typingtype;deleted_byis removed;DEFAULT_BACKEND_SORTis not exported;channel.state.*Storehandles andmutedUsersStore;WatcherState, which was in Β§4's After snippet;MutedUsersState,normalizeTimestamp,getChannelUnreadStateand*WithLocalUpdate.channel.deactivate()andclient.activeChannelsinchannel-state-ui-migration.md, and themarkReaddescription inv10-docs-impact.md.ai-migration.md(v8 β v9) has a banner pointing to this guide.How it was checked
stream-chat-jssrc/and@stream-io/i18n/state-store. All 1,292 root exports were listed with the TS compiler, and every recommended hook is a root export.package/src.Needs a decision
jumpToMessagein a screen-leveluseLayoutEffect, the SDK's jump to the latest messages may fire first. The SDK tests only cover a jump started before<Channel>mounts, so the guide recommends that order. Worth a test or a guard in the hook.Notes
release-v10.package/node_modules/stream-chatis rc.26;yarn installbrings it to rc.30.Related PRs
The three guides link to each other; review together: