Piwigo / Piwigo-Android

Piwigo Native Android App
GNU General Public License v3.0
140 stars 43 forks source link

NPE on SuccessResponse #179

Closed ramack closed 4 years ago

ramack commented 4 years ago

Describe the bug and how to reproduce

APP_VERSION_CODE=102
APP_VERSION_NAME=1.0.2
USER_COMMENT=null
SHARED_PREFERENCES=default.acra.legacyAlreadyConvertedTo4.8.0=true
    default.acra.legacyAlreadyConvertedToJson=true
    default.acra.lastVersionNr=102
ANDROID_VERSION=9
CUSTOM_DATA=
STACK_TRACE=java.lang.NullPointerException: Attempt to read from field 'boolean org.piwigo.io.model.SuccessResponse.result' on a null object reference
    at org.piwigo.io.repository.UserRepository.lambda$login$0$UserRepository(UserRepository.java:62)
    at org.piwigo.io.repository.-$$Lambda$UserRepository$zO0tfNacMVPWAm_39yB3TUZDC80.call(Unknown Source:8)
    at rx.internal.operators.OnSubscribeMap$MapSubscriber.onNext(OnSubscribeMap.java:69)
    at rx.internal.operators.OperatorObserveOn$ObserveOnSubscriber.call(OperatorObserveOn.java:224)
    at rx.android.schedulers.LooperScheduler$ScheduledAction.run(LooperScheduler.java:107)
    at android.os.Handler.handleCallback(Handler.java:873)
    at android.os.Handler.dispatchMessage(Handler.java:99)
    at android.os.Looper.loop(Looper.java:214)
    at android.app.ActivityThread.main(ActivityThread.java:6990)
    at java.lang.reflect.Method.invoke(Native Method)
    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1445)
Caused by: rx.exceptions.OnErrorThrowable$OnNextValue: OnError while emitting onNext value: retrofit2.Response.class
    at rx.internal.operators.OnSubscribeMap$MapSubscriber.onNext(OnSubscribeMap.java:73)
    ... 9 more
ramack commented 4 years ago

this (#179) and #180 might be not real crashed, but just users pressing REPORT in the show details and we not recognizing it. But e.g. in play console no crash with this exception is logged.

Those two should probably be "solved" by #182.

ramack commented 4 years ago

So this is not a real crash I'd say, just a user pushing "REPORT" in the details after entering an invalid URL... #182 will make it more clear.

If none objects, I propose to close this one here in a few days.