Skip to content

[SDK-482] 0-84#866

Open
lposen wants to merge 4 commits into
upgrade/SDK-473-0-83from
update/SDK-482-0-84
Open

[SDK-482] 0-84#866
lposen wants to merge 4 commits into
upgrade/SDK-473-0-83from
update/SDK-482-0-84

Conversation

@lposen
Copy link
Copy Markdown
Contributor

@lposen lposen commented May 20, 2026

🔹 JIRA Ticket(s) if any

✏️ Description

Please provide a brief description of what this pull request does.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 20, 2026

Lines Statements Branches Functions
Coverage: 63%
63.07% (398/631) 40.07% (103/257) 61.5% (139/226)

@qltysh
Copy link
Copy Markdown

qltysh Bot commented May 20, 2026

Qlty


Coverage Impact

This PR will not change total coverage.

Modified Files with Diff Coverage (1)

RatingFile% DiffUncovered Line #s
Coverage rating: A Coverage rating: A
src/core/classes/IterableApi.ts100.0%
Total100.0%
🚦 See full report on Qlty Cloud »

🛟 Help
  • Diff Coverage: Coverage for added or modified lines of code (excludes deleted files). Learn more.

  • Total Coverage: Coverage for the whole repository, calculated as the sum of all File Coverage. Learn more.

  • File Coverage: Covered Lines divided by Covered Lines plus Missed Lines. (Excludes non-executable lines including blank lines and comments.)

    • Indirect Changes: Changes to File Coverage for files that were not modified in this PR. Learn more.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the SDK and example app to align with React Native 0.84 (and related tooling), including changes needed for RN 0.84 TurboModule codegen constraints.

Changes:

  • Bump React Native / React / RN tooling dependencies (root + example) to RN 0.84.1 and React 19.2.3.
  • Adjust TurboModule TypeScript spec and iOS bridge signatures for RN 0.84+ codegen compatibility (notably removing T[] | null and loosening some object types).
  • Update example app platform configs (iPad orientation key, Xcode project settings, Android buildscript dependency declaration).

Reviewed changes

Copilot reviewed 10 out of 11 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
package.json Updates devDependencies and RN/React versions for RN 0.84.x.
yarn.lock Lockfile updates reflecting the RN/React/tooling bumps.
src/api/NativeRNIterableAPI.ts TurboModule spec adjustments for RN 0.84+ codegen limitations.
src/core/classes/IterableApi.ts Updates bridge calls to match the new TurboModule signature expectations.
src/core/classes/IterableConfig.ts Moves an eslint suppression to the exact != undefined line.
ios/RNIterableAPI/RNIterableAPI.mm Updates iOS TurboModule method signatures and simplifies embedded click forwarding.
example/package.json Example app dependency + Node engine updates for RN 0.84.x.
example/android/build.gradle Modifies buildscript classpath declaration for AGP.
example/ios/ReactNativeSdkExample/Info.plist Adds iPad-specific supported orientations key.
example/ios/ReactNativeSdkExample.xcodeproj/project.pbxproj Updates CocoaPods references and various target/build settings.
Build ReactNativeSdkExample_2026-05-12T16-27-11.txt Adds a local build log artifact.
Comments suppressed due to low confidence (1)

src/core/classes/IterableApi.ts:653

  • These params are typed as number[] | null, but the as number[] casts do not prevent null from being passed at runtime. The TurboModule spec was changed to require arrays (no null), so this can fail on the New Architecture. Also, the public docs currently state that null has semantic meaning ("do not change current value"), so replacing null with [] would be a behavior change unless the native side treats [] as null. Please either enforce non-null arrays in the JS API (and update docs/tests), or implement an explicit normalization strategy that preserves the existing null semantics.
    return RNIterableAPI.updateSubscriptions(
      emailListIds as number[],
      unsubscribedChannelIds as number[],
      unsubscribedMessageTypeIds as number[],
      subscribedMessageTypeIds as number[],

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 559 to 564
static getEmbeddedMessages(
placementIds: number[] | null
): Promise<IterableEmbeddedMessage[]> {
IterableLogger.log('getEmbeddedMessages: ', placementIds);
return RNIterableAPI.getEmbeddedMessages(placementIds);
return RNIterableAPI.getEmbeddedMessages(placementIds as number[]);
}
Comment on lines +104 to +110
// Subscriptions (arrays only in spec — RN codegen rejects `T[] | null`; callers
// may still pass null at the bridge when using typed assertions.)
updateSubscriptions(
emailListIds: number[] | null,
unsubscribedChannelIds: number[] | null,
unsubscribedMessageTypeIds: number[] | null,
subscribedMessageTypeIds: number[] | null,
emailListIds: number[],
unsubscribedChannelIds: number[],
unsubscribedMessageTypeIds: number[],
subscribedMessageTypeIds: number[],
Comment on lines +15 to 17
classpath("com.android.tools.build:gradle")
classpath("com.facebook.react:react-native-gradle-plugin")
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin")
Comment on lines +2 to +37
Showing All Errors Only

Build target ReactNativeSdkExample of project ReactNativeSdkExample with configuration Debug
/Users/Loren.Posen/mobile/RN/react-native-sdk/example/ios/ReactNativeSdkExample.xcodeproj: error: Failed Registering Bundle Identifier: The app identifier "iterable.reactnativesdk.example" cannot be registered to your development team because it is not available. Change your bundle identifier to a unique string to try again. (in target 'ReactNativeSdkExample' from project 'ReactNativeSdkExample')
/Users/Loren.Posen/mobile/RN/react-native-sdk/example/ios/ReactNativeSdkExample.xcodeproj: error: Provisioning profile "iOS Team Provisioning Profile: *" doesn't include the Default Web Browser capability. Default Web Browser capability needs to be assigned to your team and bundle identifier by Apple in order to be included in a profile. (in target 'ReactNativeSdkExample' from project 'ReactNativeSdkExample')
/Users/Loren.Posen/mobile/RN/react-native-sdk/example/ios/ReactNativeSdkExample.xcodeproj: error: Entitlement com.apple.developer.web-browser requires approval from Apple to include in a profile. Please request access to the associated capability. To continue building for device during request processing, remove entitlement and add upon approval. (in target 'ReactNativeSdkExample' from project 'ReactNativeSdkExample')
warning: Run script build phase 'Bundle React Native code and images' will be run during every build because it does not specify any outputs. To address this issue, either add output dependencies to the script phase, or configure it to run in every build by unchecking "Based on dependency analysis" in the script phase. (in target 'ReactNativeSdkExample' from project 'ReactNativeSdkExample')


/Users/Loren.Posen/mobile/RN/react-native-sdk/example/ios/ReactNativeSdkExample.xcodeproj: Failed Registering Bundle Identifier: The app identifier "iterable.reactnativesdk.example" cannot be registered to your development team because it is not available. Change your bundle identifier to a unique string to try again.

/Users/Loren.Posen/mobile/RN/react-native-sdk/example/ios/ReactNativeSdkExample.xcodeproj: Provisioning profile "iOS Team Provisioning Profile: *" doesn't include the Default Web Browser capability. Default Web Browser capability needs to be assigned to your team and bundle identifier by Apple in order to be included in a profile.

/Users/Loren.Posen/mobile/RN/react-native-sdk/example/ios/ReactNativeSdkExample.xcodeproj: Entitlement com.apple.developer.web-browser requires approval from Apple to include in a profile. Please request access to the associated capability. To continue building for device during request processing, remove entitlement and add upon approval.

Ld /Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Products/Debug-iphoneos/ReactNativeSdkExample.app/ReactNativeSdkExample.debug.dylib normal (in target 'ReactNativeSdkExample' from project 'ReactNativeSdkExample')
cd /Users/Loren.Posen/mobile/RN/react-native-sdk/example/ios
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -Xlinker -reproducible -target arm64-apple-ios15.1 -dynamiclib -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS26.5.sdk -O0 -L/Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Intermediates.noindex/EagerLinkingTBDs/Debug-iphoneos -L/Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Products/Debug-iphoneos -L/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS26.5.sdk/usr/lib/swift -L/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphoneos -L/Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Products/Debug-iphoneos/Iterable-React-Native-SDK -L/Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Products/Debug-iphoneos/Iterable-iOS-SDK -L/Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Products/Debug-iphoneos/RCTSwiftUI -L/Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Products/Debug-iphoneos/RCTSwiftUIWrapper -L/Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Products/Debug-iphoneos/RNGestureHandler -L/Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Products/Debug-iphoneos/RNScreens -L/Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Products/Debug-iphoneos/ReactAppDependencyProvider -L/Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Products/Debug-iphoneos/ReactCodegen -L/Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Products/Debug-iphoneos/react-native-safe-area-context -L/Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Products/Debug-iphoneos/react-native-webview -L/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphoneos -L/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS26.5.sdk/usr/lib/swift -F/Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Intermediates.noindex/EagerLinkingTBDs/Debug-iphoneos -F/Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Products/Debug-iphoneos -F/Users/Loren.Posen/mobile/RN/react-native-sdk/example/ios/Pods/React-Core-prebuilt -F/Users/Loren.Posen/mobile/RN/react-native-sdk/example/ios/Pods/ReactNativeDependencies/framework/packages/react-native -F/Users/Loren.Posen/mobile/RN/react-native-sdk/example/ios/Pods/hermes-engine/destroot/Library/Frameworks/universal -F/Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Products/Debug-iphoneos/XCFrameworkIntermediates/React-Core-prebuilt -F/Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Products/Debug-iphoneos/XCFrameworkIntermediates/ReactNativeDependencies -F/Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Products/Debug-iphoneos/XCFrameworkIntermediates/hermes-engine/Pre-built -filelist /Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Intermediates.noindex/ReactNativeSdkExample.build/Debug-iphoneos/ReactNativeSdkExample.build/Objects-normal/arm64/ReactNativeSdkExample.LinkFileList -install_name @rpath/ReactNativeSdkExample.debug.dylib -Xlinker -rpath -Xlinker /usr/lib/swift -Xlinker -rpath -Xlinker @executable_path/Frameworks -Xlinker -rpath -Xlinker @loader_path/Frameworks -Xlinker -dead_strip -Xlinker -object_path_lto -Xlinker /Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Intermediates.noindex/ReactNativeSdkExample.build/Debug-iphoneos/ReactNativeSdkExample.build/Objects-normal/arm64/ReactNativeSdkExample_lto.o -rdynamic -Xlinker -no_deduplicate -Xlinker -dependency_info -Xlinker /Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Intermediates.noindex/ReactNativeSdkExample.build/Debug-iphoneos/ReactNativeSdkExample.build/Objects-normal/arm64/ReactNativeSdkExample_dependency_info.dat -stdlib\=libc++ -fobjc-arc -fobjc-link-runtime -L/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphoneos -L/usr/lib/swift -Xlinker -add_ast_path -Xlinker /Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Intermediates.noindex/ReactNativeSdkExample.build/Debug-iphoneos/ReactNativeSdkExample.build/Objects-normal/arm64/ReactNativeSdkExample.swiftmodule -ObjC -lIterable-React-Native-SDK -lIterable-iOS-SDK -lRCTSwiftUI -lRCTSwiftUIWrapper -lRNGestureHandler -lRNScreens -lReactAppDependencyProvider -lReactCodegen -lreact-native-safe-area-context -lreact-native-webview -framework Accelerate -framework AudioToolbox -framework CoreGraphics -framework ImageIO -framework MobileCoreServices -framework QuartzCore -framework React -framework ReactNativeDependencies -framework UIKit -framework hermesvm -weak_framework JavaScriptCore -ObjC -lc++ -Xlinker -alias -Xlinker _main -Xlinker ___debug_main_executable_dylib_entry_point -lPods-ReactNativeSdkExample -o /Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Products/Debug-iphoneos/ReactNativeSdkExample.app/ReactNativeSdkExample.debug.dylib

/Users/Loren.Posen/mobile/RN/react-native-sdk/example/ios/ReactNativeSdkExample.xcodeproj: ReactNativeSdkExample: ld: warning: ignoring duplicate libraries: '-lc++'
ld: library 'Iterable-React-Native-SDK' not found
/Users/Loren.Posen/mobile/RN/react-native-sdk/example/ios/ReactNativeSdkExample.xcodeproj: ReactNativeSdkExample: clang++: error: linker command failed with exit code 1 (use -v to see invocation)

/Users/Loren.Posen/mobile/RN/react-native-sdk/example/ios/ReactNativeSdkExample.xcodeproj: Library 'Iterable-React-Native-SDK' not found


Build target Iterable-React-Native-SDK of project Pods with configuration Debug

CompileC /Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Intermediates.noindex/Pods.build/Debug-iphoneos/Iterable-React-Native-SDK.build/Objects-normal/arm64/RNIterableAPI.o /Users/Loren.Posen/mobile/RN/react-native-sdk/ios/RNIterableAPI/RNIterableAPI.mm normal arm64 objective-c++ com.apple.compilers.llvm.clang.1_0.compiler (in target 'Iterable-React-Native-SDK' from project 'Pods')
cd /Users/Loren.Posen/mobile/RN/react-native-sdk/example/ios/Pods

Using response file: /Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Intermediates.noindex/Pods.build/Debug-iphoneos/Iterable-React-Native-SDK.build/Objects-normal/arm64/af3fcb34312c57c0f52879cdce924b91-common-args.resp

/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -x objective-c++ -ivfsstatcache /Users/Loren.Posen/Library/Developer/Xcode/DerivedData/SDKStatCaches.noindex/iphoneos26.5-23F73-32daed1954a7d5dd0789fcaf2a9bb78b.sdkstatcache -target arm64-apple-ios15.1 -fmessage-length\=0 -fdiagnostics-show-note-include-stack -fmacro-backtrace-limit\=0 -fno-color-diagnostics -fmodules-prune-interval\=86400 -fmodules-prune-after\=345600 -fbuild-session-file\=/Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ModuleCache.noindex/Session.modulevalidation -fmodules-validate-once-per-build-session -Wnon-modular-include-in-framework-module -Werror\=non-modular-include-in-framework-module -Wno-trigraphs -Wno-missing-field-initializers -Wno-missing-prototypes -Werror\=return-type -Wdocumentation -Wunreachable-code -Wno-implicit-atomic-properties -Werror\=deprecated-objc-isa-usage -Wno-objc-interface-ivars -Werror\=objc-root-class -Wno-arc-repeated-use-of-weak -Wimplicit-retain-self -Wno-non-virtual-dtor -Wno-overloaded-virtual -Wno-exit-time-destructors -Wduplicate-method-match -Wno-missing-braces -Wparentheses -Wswitch -Wunused-function -Wno-unused-label -Wno-unused-parameter -Wunused-variable -Wunused-value -Wempty-body -Wuninitialized -Wconditional-uninitialized -Wno-unknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-conversion -Wconstant-conversion -Wint-conversion -Wbool-conversion -Wenum-conversion -Wno-float-conversion -Wnon-literal-null-conversion -Wobjc-literal-conversion -Wshorten-64-to-32 -Wno-newline-eof -Wno-selector -Wno-strict-selector-match -Wundeclared-selector -Wdeprecated-implementations -Wno-c++11-extensions -Wno-implicit-fallthrough -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS26.5.sdk -fstrict-aliasing -Wprotocol -Wdeprecated-declarations -Winvalid-offsetof -Wno-sign-conversion -Winfinite-recursion -Wmove -Wcomma -Wblock-capture-autoreleasing -Wstrict-prototypes -Wrange-loop-analysis -Wno-semicolon-before-method-body -Wunguarded-availability -index-store-path /Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Index.noindex/DataStore @/Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Intermediates.noindex/Pods.build/Debug-iphoneos/Iterable-React-Native-SDK.build/Objects-normal/arm64/af3fcb34312c57c0f52879cdce924b91-common-args.resp -DRCT_NEW_ARCH_ENABLED\=1 -include /Users/Loren.Posen/mobile/RN/react-native-sdk/example/ios/Pods/Target\ Support\ Files/Iterable-React-Native-SDK/Iterable-React-Native-SDK-prefix.pch -MMD -MT dependencies -MF /Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Intermediates.noindex/Pods.build/Debug-iphoneos/Iterable-React-Native-SDK.build/Objects-normal/arm64/RNIterableAPI.d --serialize-diagnostics /Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Intermediates.noindex/Pods.build/Debug-iphoneos/Iterable-React-Native-SDK.build/Objects-normal/arm64/RNIterableAPI.dia -c /Users/Loren.Posen/mobile/RN/react-native-sdk/ios/RNIterableAPI/RNIterableAPI.mm -o /Users/Loren.Posen/Library/Developer/Xcode/DerivedData/ReactNativeSdkExample-ghyslpaqbvrzvzdjqnqceksrqnul/Build/Intermediates.noindex/Pods.build/Debug-iphoneos/Iterable-React-Native-SDK.build/Objects-normal/arm64/RNIterableAPI.o -index-unit-output-path /Pods.build/Debug-iphoneos/Iterable-React-Native-SDK.build/Objects-normal/arm64/RNIterableAPI.o

In file included from /Users/Loren.Posen/mobile/RN/react-native-sdk/ios/RNIterableAPI/RNIterableAPI.mm:25:
Comment on lines 48 to +57
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
</array>
<key>UISupportedInterfaceOrientations~ipad</key>
<array>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationPortraitUpsideDown</string>
Copy link
Copy Markdown
Member

@joaodordio joaodordio left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PR description is empty. For a change this big, please add:

  • breaking changes: subscriptions/embedded null handling (with link to fix discussion above)
  • bundle ID change
  • AGP version delegation (intentional or not)
  • evidence of: example app smoke on iOS + Android, both archs; jest suite green; codegen output diff reviewed

unsubscribedChannelIds: number[] | null,
unsubscribedMessageTypeIds: number[] | null,
subscribedMessageTypeIds: number[] | null,
emailListIds: number[],
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The comment is honest about what's happening but the resulting contract is wrong. The TurboModule now declares number[] (non-null) while the public IterableApi.ts surface still accepts number[] | null, bridged by as number[] casts.

That cast silences TS but does nothing at runtime. The Iterable backend treats null as "do not change this field" and [] as "unsubscribe from everything" — those are not interchangeable. A consumer passing null today (per the documented contract) will, on the new architecture, end up unsubscribing the user from all channels of that category.

Fix should be one of:

  1. Strip null at the JS layer (in IterableApi.ts) before calling RNIterableAPI. Make the public type number[] | undefined and short-circuit to a no-op when undefined.
  2. Add an explicit null sentinel that the native side detects (e.g. [-1]) and converts back to nil on the Swift/Kotlin side.

Option 1 is cleaner. Either way, this needs:

  • a Jest test that proves null does not become []
  • a CHANGELOG entry calling out the public API change
  • a paired docs PR

Comment on lines 559 to 564
static getEmbeddedMessages(
placementIds: number[] | null
): Promise<IterableEmbeddedMessage[]> {
IterableLogger.log('getEmbeddedMessages: ', placementIds);
return RNIterableAPI.getEmbeddedMessages(placementIds);
return RNIterableAPI.getEmbeddedMessages(placementIds as number[]);
}
Copy link
Copy Markdown
Member

@joaodordio joaodordio May 21, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These casts hide a real runtime mismatch (see comment on NativeRNIterableAPI.ts). Could we replace with explicit normalization, e.g.:

if (placementIds == null) {
  // backend semantics: omit field. Either skip the call or pass a sentinel.
  return Promise.resolve([]);
}
return RNIterableAPI.getEmbeddedMessages(placementIds);

and for updateSubscriptions, drop null inputs from the args object before calling the bridge.

}
dependencies {
classpath('com.android.tools.build:gradle:8.7.2')
classpath("com.android.tools.build:gradle")
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The AGP version was stripped ('com.android.tools.build:gradle:8.7.2'"com.android.tools.build:gradle"). This silently delegates the AGP version to the react-native-gradle-plugin's BOM. If that's intentional for RN 0.84, please add a Groovy comment explaining why, since:

  • Gradle 9 may warn on classpath deps without coordinates
  • the AGP version will now float with every RN patch
  • consumers customizing buildscript dependency order can hit unexpected resolutions
    If unintentional, pin to whatever AGP RN 0.84.1 ships with.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants