Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error when call createConfig on android #402

Open
dioi2000 opened this issue Dec 26, 2023 · 2 comments
Open

error when call createConfig on android #402

dioi2000 opened this issue Dec 26, 2023 · 2 comments
Labels
bug Something isn't working

Comments

@dioi2000
Copy link

dioi2000 commented Dec 26, 2023

Describe the bug?

error when call createConfig on android
(newArchEnabled=true, false both)

What is expected to happen?

no error with createConfig

What is the actual behavior?

createConfig fail with error

Exception in native call
java.lang.NullPointerException: Attempt to invoke virtual method 'boolean java.lang.Boolean.booleanValue()' on a null object reference
at com.facebook.react.bridge.ReadableNativeArray.getBoolean(ReadableNativeArray.java:87)
at com.facebook.react.bridge.JavaMethodWrapper$1.extractArgument(JavaMethodWrapper.java:37)
at com.facebook.react.bridge.JavaMethodWrapper$1.extractArgument(JavaMethodWrapper.java:33)
at com.facebook.react.bridge.JavaMethodWrapper.invoke(JavaMethodWrapper.java:356)
at com.facebook.react.bridge.JavaModuleWrapper.invoke(JavaModuleWrapper.java:188)
at com.facebook.jni.NativeRunnable.run(Native Method)
at android.os.Handler.handleCallback(Handler.java:942)
at android.os.Handler.dispatchMessage(Handler.java:99)
at com.facebook.react.bridge.queue.MessageQueueThreadHandler.dispatchMessage(MessageQueueThreadHandler.java:27)
at android.os.Looper.loopOnce(Looper.java:211)
at android.os.Looper.loop(Looper.java:300)
at com.facebook.react.bridge.queue.MessageQueueThreadImpl$4.run(MessageQueueThreadImpl.java:228)
at java.lang.Thread.run(Thread.java:1012)

Reproduction Steps?

await createConfig({
clientId: '--------------',
redirectUri: 'com.-----.appname:/okta',
endSessionRedirectUri: 'com.-----.appname:/logout',
discoveryUri: 'https://------.---------.com/',
scopes: ["openid", "profile", "offline_access"],
});

Additional Information?

"dependencies": {
"@eliav2/react-native-collapsible-view": "^1.5.1",
"@okta/okta-react-native": "^2.10.0",
"@react-native-async-storage/async-storage": "^1.21.0",
"@react-native-clipboard/clipboard": "1.11.2",
"@react-native-firebase/app": "^18.7.1",
"@react-native-firebase/messaging": "^18.7.1",
"@react-navigation/bottom-tabs": "^6.5.11",
"@react-navigation/drawer": "^6.6.6",
"@react-navigation/native": "^6.1.9",
"@react-navigation/stack": "^6.3.20",
"@sourcetoad/react-native-sketch-canvas": "^1.0.4",
"dayjs": "^1.11.10",
"react": "18.2.0",
"react-native": "^0.72.7",
"react-native-blob-util": "^0.19.6",
"react-native-calendars": "^1.1302.0",
"react-native-draggable-flatlist": "^4.0.1",
"react-native-drawer-layout": "^3.2.1",
"react-native-dropdown-picker": "^5.4.6",
"react-native-email-link": "^1.14.7",
"react-native-fast-image": "git+https://github.com/numandev1/react-native-fast-image#feat/fabric-wolewicki",
"react-native-fs": "^2.20.0",
"react-native-gesture-handler": "^2.14.0",
"react-native-linear-gradient": "^2.8.3",
"react-native-localization": "^2.3.2",
"react-native-maps": "^1.8.4",
"react-native-pdf": "^6.7.4",
"react-native-reanimated": "^3.6.1",
"react-native-render-html": "^6.3.4",
"react-native-reorderable-list": "^0.4.0",
"react-native-safe-area-context": "4.7.4",
"react-native-screens": "3.27.0",
"react-native-simple-default-props": "^1.0.0",
"react-native-simple-toast": "^3.2.0",
"react-native-svg": "14.0.0",
"react-native-svg-charts": "^5.4.0",
"react-native-video": "^5.2.1",
"react-native-webview": "^13.6.3",
"recoil": "^0.7.7"
},

SDK Version

2.10.0

Build Information

Redmi Pad SE 23073RPBFL
Android 13

android
gradle 8.0.1
Apple M1 Pro / 14.1.1(23B81)

@dioi2000 dioi2000 added the bug Something isn't working label Dec 26, 2023
@rajdeepnanua-okta
Copy link
Contributor

rajdeepnanua-okta commented Jan 2, 2024

Hi @dioi2000, thanks for filing this bug. Unfortunately, I don't see anything obvious that could be causing this issue. I also tried reproducing a similar setup, but was unable to run into this crash. Is this issue reproducible for you locally? If so, could you run 'adb logcat' while reproducing this issue, and check the output for any exceptions being thrown in com.okta.oidc.* or com.oktareactnative.* packages? This issue happens if the Android bridge code doesn't resolve the promise for createConfig, which should happen if there's a runtime exception happening in the Android bridge.

@spearmootz
Copy link

@dioi2000 i had this same issue. make sure to declare the property requireHardwareBackedKeyStore on the config.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants