-
Notifications
You must be signed in to change notification settings - Fork 41
Description
A crash was reported in production (via Crashlytics) related to SessionHelper.hide in the React Native Adyen Drop-in integration.
The crash message suggests a mismatch between the number of arguments passed from the JavaScript side and the parameters expected by the native module.
Crash log:
Fatal Exception: com.facebook.react.bridge.NativeArgumentsParseException: SessionHelper.hide got 1 arguments, expected 2
at com.facebook.react.bridge.JavaMethodWrapper.invoke(JavaMethodWrapper.java:349)
at com.facebook.react.bridge.JavaModuleWrapper.invoke(JavaModuleWrapper.java:146)
at com.facebook.jni.NativeRunnable.run(NativeRunnable.java)
at android.os.Handler.handleCallback(Handler.java:873)
at android.os.Handler.dispatchMessage(Handler.java:99)
at com.facebook.react.bridge.queue.MessageQueueThreadHandler.dispatchMessage(MessageQueueThreadHandler.kt:20)
at android.os.Looper.loop(Looper.java:193)
at com.facebook.react.bridge.queue.MessageQueueThreadImpl$Companion.startNewBackgroundThread$lambda$1(MessageQueueThreadImpl.kt:175)
at java.lang.Thread.run(Thread.java:764)
It seems that the native bridge expects two parameters, but the JS call might only be providing one.
Since this was reported from production, I’m not sure under what conditions it happens.
To Reproduce
Unfortunately, I haven’t been able to reproduce this locally.
It was reported automatically via Crashlytics from a production build, so I don’t have exact reproduction steps.
It likely occurs during or after a checkout session when the Drop-in UI is being dismissed.
Expected behavior
Ideally, SessionHelper.hide should not crash if it receives fewer arguments — or there should be clear documentation on how to call it correctly.
Screenshots
N/A – crash occurs natively, no visible UI impact before crash.
Smartphone (please complete the following information):
- Device: Saturn1000F2 (multiple production devices)
- OS: Android (various versions)
- React Native version: 0.79.5
- Adyen Drop-in version: 2.8.0
Additional context
- The crash only appears in production (via Crashlytics).
- It’s unclear if the second parameter is meant to be optional.
- Would appreciate clarification on the expected arguments for
SessionHelper.hideor guidance on ensuring correct usage.