[NOJIRA] [FIX] Session Replay build issues#1256
Conversation
There was a problem hiding this comment.
Pull request overview
This PR targets Session Replay build stability for newer React Native versions by updating the iOS podspec configuration and ensuring the Metro-side asset watcher doesn’t keep the Node process alive after bundling.
Changes:
- Refactors the Session Replay podspec to remove Folly compiler flags and restructure how new-architecture dependencies/xcconfig are applied.
- Updates the Metro asset bundler to close the chokidar watcher after bundle completion to allow CI/release Node processes to exit.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| packages/react-native-session-replay/src/metro/index.ts | Switches from a boolean “watching” guard to a stored watcher instance and closes it after certain Metro reporter events. |
| packages/react-native-session-replay/DatadogSDKReactNativeSessionReplay.podspec | Removes Folly flags and reorganizes install_modules_dependencies + xcconfig application around RCT_NEW_ARCH_ENABLED. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
I am running E2E tests (#108489552) to check for regressions before approving. |
| require "json" | ||
|
|
||
| package = JSON.parse(File.read(File.join(__dir__, "package.json"))) | ||
| folly_compiler_flags = '-DFOLLY_CFG_NO_COROUTINES=1 -DFOLLY_NO_CONFIG -DFOLLY_MOBILE=1 -DFOLLY_USE_LIBCPP=1 -Wno-comma -Wno-shorten-64-to-32' |
There was a problem hiding this comment.
As previously discussed, I would keep the old flags for previous versions, and only change them for the newer ones.
There was a problem hiding this comment.
The thing is, we don't set this flags in any other podspec on the SDK. I also ran the E2E suite against this PR and it builds properly even on RN 0.65.
marco-saia-datadog
left a comment
There was a problem hiding this comment.
E2E tests are all green, I believe it's safe to merge.
What does this PR do?
This PR does two things:
Additional Notes
Tested on an specific Expo 54.0.33 RN 0.81.5 test app.
Review checklist (to be filled by reviewers)