You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
E/AndroidRuntime: FATAL EXCEPTION: main
Process: de.westnordost.streetcomplete, PID: 16629
java.lang.NullPointerException: closeButton must not be null
at de.westnordost.streetcomplete.quests.AbstractBottomSheetFragment.updateCloseButtonVisibility(AbstractBottomSheetFragment.kt:145)
at de.westnordost.streetcomplete.quests.AbstractBottomSheetFragment.access$updateCloseButtonVisibility(AbstractBottomSheetFragment.kt:31)
at de.westnordost.streetcomplete.quests.AbstractBottomSheetFragment$onViewCreated$5.onSlide(AbstractBottomSheetFragment.kt:94)
at com.google.android.material.bottomsheet.BottomSheetBehavior.dispatchOnSlide(BottomSheetBehavior.java:1498)
at com.google.android.material.bottomsheet.BottomSheetBehavior$4.onViewPositionChanged(BottomSheetBehavior.java:1365)
at androidx.customview.widget.ViewDragHelper.continueSettling(ViewDragHelper.java:750)
at com.google.android.material.bottomsheet.BottomSheetBehavior$SettleRunnable.run(BottomSheetBehavior.java:1537)
at android.view.Choreographer$CallbackRecord.run(Choreographer.java:972)
at android.view.Choreographer.doCallbacks(Choreographer.java:796)
at android.view.Choreographer.doFrame(Choreographer.java:727)
at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:957)
at android.os.Handler.handleCallback(Handler.java:938)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:223)
at android.app.ActivityThread.main(ActivityThread.java:7660)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:592)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:947)
How to Reproduce
I am not able to reproduce this crash, but I think it happened after returning to the app from the background while a quest sheet was shown.
Versions affected
v28.0-beta2
The text was updated successfully, but these errors were encountered:
I think this bug is not new, nothing changed there for quite some time.
I also think that your assumption is correct: It must have something to do when the app comes back from the background. In particular, what I think is going on is that the MainActivity is recreated but the callback for when the bottom sheet (the quest form) is sliding up or down is still being done on the old AbstractBottomSheetFragment that was part of the old MainActivity before it was recreated. Thus, AbstractBottomSheetFragment doesn't actually have a view attached anymore because the old view had been destroyed. So basically, this is a memory leak. That's my assumption at least.
My app crashed with the following stack trace:
How to Reproduce
I am not able to reproduce this crash, but I think it happened after returning to the app from the background while a quest sheet was shown.
Versions affected
v28.0-beta2
The text was updated successfully, but these errors were encountered: