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

Android crash #388

Closed
LucaIaconelli opened this issue Nov 14, 2022 · 2 comments
Closed

Android crash #388

LucaIaconelli opened this issue Nov 14, 2022 · 2 comments

Comments

@LucaIaconelli
Copy link

Greetings,

I am experiencing a crash on Android when I try to make the authorizeAndExchangeCode call.

flutter_appauth: ^4.2.1
Flutter 3.3.8

D/AndroidRuntime( 8811): Shutting down VM
E/AndroidRuntime( 8811): FATAL EXCEPTION: main
E/AndroidRuntime( 8811): Process: com.renoon.fashion, PID: 8811
E/AndroidRuntime( 8811): java.lang.NullPointerException: Attempt to invoke virtual method 'boolean java.lang.String.equals(java.lang.Object)' on a null object reference
E/AndroidRuntime( 8811): 	at net.openid.appauth.IdToken.validate(IdToken.java:232)
E/AndroidRuntime( 8811): 	at net.openid.appauth.AuthorizationService$TokenRequestTask.onPostExecute(AuthorizationService.java:710)
E/AndroidRuntime( 8811): 	at net.openid.appauth.AuthorizationService$TokenRequestTask.onPostExecute(AuthorizationService.java:579)
E/AndroidRuntime( 8811): 	at android.os.AsyncTask.finish(AsyncTask.java:771)
E/AndroidRuntime( 8811): 	at android.os.AsyncTask.access$900(AsyncTask.java:199)
E/AndroidRuntime( 8811): 	at android.os.AsyncTask$InternalHandler.handleMessage(AsyncTask.java:788)
E/AndroidRuntime( 8811): 	at android.os.Handler.dispatchMessage(Handler.java:106)
E/AndroidRuntime( 8811): 	at android.os.Looper.loop(Looper.java:223)
E/AndroidRuntime( 8811): 	at android.app.ActivityThread.main(ActivityThread.java:7656)
E/AndroidRuntime( 8811): 	at java.lang.reflect.Method.invoke(Native Method)
E/AndroidRuntime( 8811): 	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:592)
E/AndroidRuntime( 8811): 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:947)
I/Process ( 8811): Sending signal. PID: 8811 SIG: 9
Lost connection to device.

Could you help me identify the problem?

Thanks in advance

@lsaudon
Copy link
Contributor

lsaudon commented Nov 21, 2022

Maybe your idToken is null.

@MaikuB
Copy link
Owner

MaikuB commented Jan 14, 2023

You would need to debug this further yourself but as mentioned by @lsaudon, looks like it could from how the id token is null

@MaikuB MaikuB closed this as completed Jan 14, 2023
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

No branches or pull requests

3 participants