Repository navigation
Rea4 to 0.86.0 discord - #65
Merged
Merged
Conversation
This reverts commit 9eee718. The shadowTreeCommitSucceeded / shadowTreeCommitFinalized hooks existed only to make Reanimated's props-registry equality eviction race-free. That eviction turned out to be performance neutral and has been removed from the Reanimated fork, so nothing overrides these hooks anymore and the fork can drop the divergence from upstream in ShadowTree, ShadowTreeDelegate, UIManager and UIManagerCommitHook. Also restores the configureEventEmitterCallback() call in SampleTurboModuleSpec.cpp, which that commit had incidentally commented out. Co-authored-by: Cursor <cursoragent@cursor.com>
Adds the `enableMountingCoordinatorPullModelAndroid` experiment flag (default off) that gates the Android pull-model mounting migration. Config entry plus regenerated accessors only - no behavior change. Cherry-pick of react/react-native@ece0efe. The generated feature flag files conflicted because this fork's flag set has diverged from upstream, so they were regenerated from the config with `yarn featureflags` instead of being merged by hand. Co-authored-by: Cursor <cursoragent@cursor.com>
Flip the flag's defaultValue to true and regenerate the feature-flag boilerplate with `yarn featureflags --update`. The config's own metadata already declared expectedReleaseValue: true. Neither app-side provider overrides the flag, so the default applies directly: ReactNativeNewArchitectureFeatureFlagsDefaults (Android) and ReactNativeFeatureFlagsOverridesOSSStable (iOS) both inherit it. Note: this is inert on this branch. The flag has no consumers here or upstream at ece0efe -- that commit only defines it, and the migration it gates (PullTransactionMountItem enqueued in MountItemDispatcher, so the UI thread pulls the transaction instead of the commit thread building the batch in schedulerShouldRenderTransactions) lands in later upstream commits that are not cherry-picked here. Setting true now records intent so the path is on once the implementation arrives. This is a separate mechanism from usePullModelOnAndroid, which this fork already defaults to true and which does have consumers in FabricUIManagerBinding.cpp and FabricUIManager.java. Upstream has since removed that flag, having graduated it. Before the implementation is backported, check the dependencies named in the flag description: enableAccumulatedUpdatesInRawPropsAndroid is already true, but enableExclusivePropsUpdateAndroid and enablePropsUpdateReconciliationAndroid are both still false, and the latter two are required when Props 2.0 is in use. Co-authored-by: Cursor <cursoragent@cursor.com>
Reanimated requires this React Native flag to be enabled before its own DISABLE_COMMIT_PAUSING_MECHANISM flag can be turned on safely; without it, React commits can be starved and the app becomes unresponsive. See https://docs.swmansion.com/react-native-reanimated/docs/guides/feature-flags/#disable_commit_pausing_mechanism Co-authored-by: Cursor <cursoragent@cursor.com>
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.
Summary
Merges the Reanimated 4 changes from
rea4-discordinto0.86.0-discord, so the main fork branch matches what the client ships today.discord/discord#339627 (the Reanimated 4.8 + react-native-worklets upgrade) pinned the client to
0.86.0-discord-rea4-5, a release built from a side branch (rea4-discord). The rest of the fork's release flow targets0.86.0-discord. Theclyde ci bump-external-react-native-versionpipeline uses it as the default branch, so if these commits stay only onrea4-discord, the next routine RN bump will ship without them and break the Reanimated 4 setup.This PR contains only the 4 code commits from
rea4-discord. It leaves out the CI-generatedUpdated version to 0.86.0-discord-rea4-5commit: that version string doesn't follow the<upstream>-discord-<n>format the release script parses, so the next pipeline run would fail on it.rea4-discordwas branched from0.86.0-discord-32, the current head of0.86.0-discord, so this PR is a clean fast-forward with no conflicts.Changes
Revert "[Android] shadow-tree commit-lifecycle hooks (react#100)" (
a239c8e7)The
shadowTreeCommitSucceeded/shadowTreeCommitFinalizedhooks existed only so Reanimated's props-registry equality eviction could be race-free. That eviction turned out to have no performance impact and was removed from our Reanimated fork, so nothing uses these hooks anymore. Reverting removes our divergence from upstream inShadowTree,ShadowTreeDelegate,UIManagerandUIManagerCommitHook. It also restores theconfigureEventEmitterCallback()call inSampleTurboModuleSpec.cpp, which the original commit had commented out by accident.Add
enableMountingCoordinatorPullModelAndroidfeature flag (eeefbe15)Cherry-pick of react/react-native@ece0efe (react#57581). It adds the flag definition and its generated accessors, with no behavior change. The generated files were regenerated with
yarn featureflagsbecause our flag set has diverged from upstream.Default
enableMountingCoordinatorPullModelAndroidto true (71d8fec5)This records intent and has no effect for now. Nothing reads the flag yet, because the Android pull-model mounting migration it gates lands in later upstream commits we haven't cherry-picked. Before that migration is backported,
enableExclusivePropsUpdateAndroidandenablePropsUpdateReconciliationAndroid, which are both still false, need to be revisited.Enable
preventShadowTreeCommitExhaustionby default (d6ffd1d9)Reanimated requires this flag before its
DISABLE_COMMIT_PAUSING_MECHANISMflag can be turned on safely. Without it, React commits can be starved and the app stops responding. This is a prerequisite for discord/discord#317388. See the Reanimated feature flags docs.Impact
None for the client. The code is identical to
0.86.0-discord-rea4-5, which the client already runs. The only difference is the version string.After merge
0.86.0-discord-33and push the matching tag.clyde mobile set-react-native-version 0.86.0-discord-33 <sha>to point the client back to the0.86.0-discordline.rea4-discordcan then be deleted. Keep the0.86.0-discord-rea4-5tag, because older monorepo commits reference it.