patzly / grocy-android

ERP beyond your fridge, now on your phone – An awesome companion app for grocy
https://patrickzedler.com/grocy/
GNU General Public License v3.0
829 stars 80 forks source link

App crashes when editing Master Data #831

Closed YoMamasNerd closed 5 months ago

YoMamasNerd commented 5 months ago

When adding new items in the Master Data section the app crashes. Data is still written. This but is reproducible on my end.

--------- beginning of crash
01-26 23:50:07.751 14045 14045 E AndroidRuntime: FATAL EXCEPTION: main
01-26 23:50:07.751 14045 14045 E AndroidRuntime: Process: xyz.zedler.patrick.grocy, PID: 14045
01-26 23:50:07.751 14045 14045 E AndroidRuntime: java.lang.NullPointerException: Attempt to read from field 'androidx.core.view.WindowInsetsAnimationCompat$Impl androidx.core.view.WindowInsetsAnimationCompat.mImpl' on a null object reference in method 'androidx.core.view.WindowInsetsCompat xyz.zedler.patrick.grocy.util.UiUtil$1.onProgress(androidx.core.view.WindowInsetsCompat, java.util.List)'
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at xyz.zedler.patrick.grocy.util.UiUtil$1.onProgress(UiUtil.java:13)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at androidx.core.view.WindowInsetsAnimationCompat$Impl30$ProxyCallback.onProgress(WindowInsetsAnimationCompat.java:72)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at android.view.View.dispatchWindowInsetsAnimationProgress(View.java:12162)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7614)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7620)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7620)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7620)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7620)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7620)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at android.view.ViewRootInsetsControllerHost.dispatchWindowInsetsAnimationProgress(ViewRootInsetsControllerHost.java:108)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at android.view.InsetsController.lambda$new$3(InsetsController.java:818)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at android.view.InsetsController.$r8$lambda$meqKUiuVHZJFS86fhQQzBBmdABw(Unknown Source:0)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at android.view.InsetsController$$ExternalSyntheticLambda9.run(D8$$SyntheticClass:0)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1399)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1408)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at android.view.Choreographer.doCallbacks(Choreographer.java:1008)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at android.view.Choreographer.doFrame(Choreographer.java:935)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:1382)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at android.os.Handler.handleCallback(Handler.java:959)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at android.os.Handler.dispatchMessage(Handler.java:100)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at android.os.Looper.loopOnce(Looper.java:232)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at android.os.Looper.loop(Looper.java:317)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at android.app.ActivityThread.main(ActivityThread.java:8501)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at java.lang.reflect.Method.invoke(Native Method)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:552)
01-26 23:50:07.751 14045 14045 E AndroidRuntime:    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:878)
--------- beginning of main
01-26 23:50:09.245 14279 14279 E r.patrick.grocy: Not starting debugger since process cannot load the jdwp agent.
01-26 23:50:25.615 14279 14279 E AndroidRuntime: FATAL EXCEPTION: main
01-26 23:50:25.615 14279 14279 E AndroidRuntime: Process: xyz.zedler.patrick.grocy, PID: 14279
01-26 23:50:25.615 14279 14279 E AndroidRuntime: java.lang.NullPointerException: Attempt to read from field 'androidx.core.view.WindowInsetsAnimationCompat$Impl androidx.core.view.WindowInsetsAnimationCompat.mImpl' on a null object reference in method 'androidx.core.view.WindowInsetsCompat xyz.zedler.patrick.grocy.util.UiUtil$1.onProgress(androidx.core.view.WindowInsetsCompat, java.util.List)'
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at xyz.zedler.patrick.grocy.util.UiUtil$1.onProgress(UiUtil.java:13)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at androidx.core.view.WindowInsetsAnimationCompat$Impl30$ProxyCallback.onProgress(WindowInsetsAnimationCompat.java:72)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at android.view.View.dispatchWindowInsetsAnimationProgress(View.java:12162)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7614)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7620)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7620)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7620)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7620)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7620)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at android.view.ViewRootInsetsControllerHost.dispatchWindowInsetsAnimationProgress(ViewRootInsetsControllerHost.java:108)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at android.view.InsetsController.lambda$new$3(InsetsController.java:818)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at android.view.InsetsController.$r8$lambda$meqKUiuVHZJFS86fhQQzBBmdABw(Unknown Source:0)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at android.view.InsetsController$$ExternalSyntheticLambda9.run(D8$$SyntheticClass:0)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1399)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1408)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at android.view.Choreographer.doCallbacks(Choreographer.java:1008)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at android.view.Choreographer.doFrame(Choreographer.java:935)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:1382)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at android.os.Handler.handleCallback(Handler.java:959)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at android.os.Handler.dispatchMessage(Handler.java:100)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at android.os.Looper.loopOnce(Looper.java:232)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at android.os.Looper.loop(Looper.java:317)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at android.app.ActivityThread.main(ActivityThread.java:8501)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at java.lang.reflect.Method.invoke(Native Method)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:552)
01-26 23:50:25.615 14279 14279 E AndroidRuntime:    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:878)
01-26 23:50:27.697 14403 14403 E r.patrick.grocy: Not starting debugger since process cannot load the jdwp agent.
01-26 23:50:49.826 14403 14403 E AndroidRuntime: FATAL EXCEPTION: main
01-26 23:50:49.826 14403 14403 E AndroidRuntime: Process: xyz.zedler.patrick.grocy, PID: 14403
01-26 23:50:49.826 14403 14403 E AndroidRuntime: java.lang.NullPointerException: Attempt to read from field 'androidx.core.view.WindowInsetsAnimationCompat$Impl androidx.core.view.WindowInsetsAnimationCompat.mImpl' on a null object reference in method 'androidx.core.view.WindowInsetsCompat xyz.zedler.patrick.grocy.util.UiUtil$1.onProgress(androidx.core.view.WindowInsetsCompat, java.util.List)'
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at xyz.zedler.patrick.grocy.util.UiUtil$1.onProgress(UiUtil.java:13)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at androidx.core.view.WindowInsetsAnimationCompat$Impl30$ProxyCallback.onProgress(WindowInsetsAnimationCompat.java:72)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at android.view.View.dispatchWindowInsetsAnimationProgress(View.java:12162)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7614)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7620)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7620)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7620)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7620)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7620)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at android.view.ViewRootInsetsControllerHost.dispatchWindowInsetsAnimationProgress(ViewRootInsetsControllerHost.java:108)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at android.view.InsetsController.lambda$new$3(InsetsController.java:818)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at android.view.InsetsController.$r8$lambda$meqKUiuVHZJFS86fhQQzBBmdABw(Unknown Source:0)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at android.view.InsetsController$$ExternalSyntheticLambda9.run(D8$$SyntheticClass:0)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1399)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1408)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at android.view.Choreographer.doCallbacks(Choreographer.java:1008)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at android.view.Choreographer.doFrame(Choreographer.java:935)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:1382)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at android.os.Handler.handleCallback(Handler.java:959)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at android.os.Handler.dispatchMessage(Handler.java:100)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at android.os.Looper.loopOnce(Looper.java:232)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at android.os.Looper.loop(Looper.java:317)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at android.app.ActivityThread.main(ActivityThread.java:8501)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at java.lang.reflect.Method.invoke(Native Method)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:552)
01-26 23:50:49.826 14403 14403 E AndroidRuntime:    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:878)
01-26 23:50:51.076 14551 14551 E r.patrick.grocy: Not starting debugger since process cannot load the jdwp agent.
01-26 23:52:33.276 14551 14551 E AndroidRuntime: FATAL EXCEPTION: main
01-26 23:52:33.276 14551 14551 E AndroidRuntime: Process: xyz.zedler.patrick.grocy, PID: 14551
01-26 23:52:33.276 14551 14551 E AndroidRuntime: java.lang.NullPointerException: Attempt to read from field 'androidx.core.view.WindowInsetsAnimationCompat$Impl androidx.core.view.WindowInsetsAnimationCompat.mImpl' on a null object reference in method 'androidx.core.view.WindowInsetsCompat xyz.zedler.patrick.grocy.util.UiUtil$1.onProgress(androidx.core.view.WindowInsetsCompat, java.util.List)'
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at xyz.zedler.patrick.grocy.util.UiUtil$1.onProgress(UiUtil.java:13)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at androidx.core.view.WindowInsetsAnimationCompat$Impl30$ProxyCallback.onProgress(WindowInsetsAnimationCompat.java:72)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at android.view.View.dispatchWindowInsetsAnimationProgress(View.java:12162)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7614)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7620)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7620)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7620)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7620)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7620)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at android.view.ViewRootInsetsControllerHost.dispatchWindowInsetsAnimationProgress(ViewRootInsetsControllerHost.java:108)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at android.view.InsetsController.lambda$new$3(InsetsController.java:818)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at android.view.InsetsController.$r8$lambda$meqKUiuVHZJFS86fhQQzBBmdABw(Unknown Source:0)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at android.view.InsetsController$$ExternalSyntheticLambda9.run(D8$$SyntheticClass:0)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1399)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1408)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at android.view.Choreographer.doCallbacks(Choreographer.java:1008)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at android.view.Choreographer.doFrame(Choreographer.java:935)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:1382)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at android.os.Handler.handleCallback(Handler.java:959)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at android.os.Handler.dispatchMessage(Handler.java:100)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at android.os.Looper.loopOnce(Looper.java:232)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at android.os.Looper.loop(Looper.java:317)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at android.app.ActivityThread.main(ActivityThread.java:8501)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at java.lang.reflect.Method.invoke(Native Method)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:552)
01-26 23:52:33.276 14551 14551 E AndroidRuntime:    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:878)
01-26 23:52:35.800 14958 14958 E r.patrick.grocy: Not starting debugger since process cannot load the jdwp agent.
01-26 23:52:46.980 14958 14958 E ViewUtil: icon animation requires AnimVectorDrawable
01-26 23:52:50.361 14958 14958 E ViewUtil: icon animation requires AnimVectorDrawable
BuyakaBuyak commented 5 months ago

Same here. Fresh grocy Installation. whenever I save a changw to the Master data (Stammdaten) the app crashes yet still writes the changes to the server.

patzly commented 5 months ago

Very strange, I cannot reproduce it on any of my devices :/ Thanks for the logcat, but sadly it isn't very helpful because it points on an internal field which seems to be not initialized on your devices, but when it works on other devices like mine it's very hard to find the cause I think...

patzly commented 5 months ago

Maybe there is a setting required to turn off keyboard animation as a workaround, as the animation callback causes the crash.

YoMamasNerd commented 5 months ago

I'm running the app on my Google Pixel 6 with the latest Android 14 beta. The server is running on my local TrueNas server. Is there something or some log that would help you?

patzly commented 5 months ago

@YoMamasNerd I testet it yesterday on my Pixel 6 with Android 14 Beta, too, but the different behavior is hard to explain... Could you please give the specific steps you can perform on the demo server to reproduce the issue? Maybe I miss something?

YoMamasNerd commented 5 months ago

@patzly Here is the video to reproduce the crash

patzly commented 5 months ago

Ah now I'm able to reproduce it with locations! I only tested it with products, but they seem to work.

YoMamasNerd commented 5 months ago

Great, glad I could help a little bit

patzly commented 5 months ago

@YoMamasNerd @BuyakaBuyak A temporary workaround until we release the next version with the fix included is to close the keyboard manually before saving. That prevents the keyboard animation to run while the app is navigating back to the previous page. Hope this workaround works for you! Else you could use the nightly build instead.

X-Nightmare-X commented 4 months ago

The nightly build (downloaded 1 day ago) has the same failure on my Galaxy S21. Commented it on Google Play too. I will look for the workaround with the keyboard. It safes the changes but clothes as mentioned above.

patzly commented 4 months ago

@X-Nightmare-X Can you please attach your crash log from the nightly build?

patzly commented 4 months ago

@X-Nightmare-X This would be important as we want to release the next version😅

YoMamasNerd commented 4 months ago

@X-Nightmare-X Can you please attach your crash log from the nightly build?

@patzly I'm able to reproduce the crash with the latest nightly too.

--------- beginning of crash
02-21 12:28:00.908 31609 31609 E AndroidRuntime: FATAL EXCEPTION: main
02-21 12:28:00.908 31609 31609 E AndroidRuntime: Process: xyz.zedler.patrick.grocy.nightly.debug, PID: 31609
02-21 12:28:00.908 31609 31609 E AndroidRuntime: java.lang.NullPointerException: Attempt to invoke virtual method 'float androidx.core.view.WindowInsetsAnimationCompat.getInterpolatedFraction()' on a null object reference
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at xyz.zedler.patrick.grocy.util.UiUtil$1.onProgress(UiUtil.java:334)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at androidx.core.view.WindowInsetsAnimationCompat$Impl30$ProxyCallback.onProgress(WindowInsetsAnimationCompat.java:1072)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at android.view.View.dispatchWindowInsetsAnimationProgress(View.java:12173)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7624)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7630)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7630)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7630)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7630)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7630)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at android.view.ViewRootInsetsControllerHost.dispatchWindowInsetsAnimationProgress(ViewRootInsetsControllerHost.java:108)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at android.view.InsetsController.lambda$new$3(InsetsController.java:818)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at android.view.InsetsController.$r8$lambda$meqKUiuVHZJFS86fhQQzBBmdABw(Unknown Source:0)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at android.view.InsetsController$$ExternalSyntheticLambda10.run(D8$$SyntheticClass:0)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1406)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1415)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at android.view.Choreographer.doCallbacks(Choreographer.java:1015)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at android.view.Choreographer.doFrame(Choreographer.java:942)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:1389)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at android.os.Handler.handleCallback(Handler.java:959)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at android.os.Handler.dispatchMessage(Handler.java:100)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at android.os.Looper.loopOnce(Looper.java:232)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at android.os.Looper.loop(Looper.java:317)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at android.app.ActivityThread.main(ActivityThread.java:8516)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at java.lang.reflect.Method.invoke(Native Method)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:552)
02-21 12:28:00.908 31609 31609 E AndroidRuntime:    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:878)
02-21 12:29:32.715 31846 31846 E AndroidRuntime: FATAL EXCEPTION: main
02-21 12:29:32.715 31846 31846 E AndroidRuntime: Process: xyz.zedler.patrick.grocy.nightly.debug, PID: 31846
02-21 12:29:32.715 31846 31846 E AndroidRuntime: java.lang.NullPointerException: Attempt to invoke virtual method 'float androidx.core.view.WindowInsetsAnimationCompat.getInterpolatedFraction()' on a null object reference
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at xyz.zedler.patrick.grocy.util.UiUtil$1.onProgress(UiUtil.java:334)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at androidx.core.view.WindowInsetsAnimationCompat$Impl30$ProxyCallback.onProgress(WindowInsetsAnimationCompat.java:1072)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at android.view.View.dispatchWindowInsetsAnimationProgress(View.java:12173)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7624)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7630)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7630)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7630)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7630)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7630)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at android.view.ViewRootInsetsControllerHost.dispatchWindowInsetsAnimationProgress(ViewRootInsetsControllerHost.java:108)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at android.view.InsetsController.lambda$new$3(InsetsController.java:818)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at android.view.InsetsController.$r8$lambda$meqKUiuVHZJFS86fhQQzBBmdABw(Unknown Source:0)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at android.view.InsetsController$$ExternalSyntheticLambda10.run(D8$$SyntheticClass:0)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1406)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1415)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at android.view.Choreographer.doCallbacks(Choreographer.java:1015)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at android.view.Choreographer.doFrame(Choreographer.java:942)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:1389)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at android.os.Handler.handleCallback(Handler.java:959)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at android.os.Handler.dispatchMessage(Handler.java:100)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at android.os.Looper.loopOnce(Looper.java:232)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at android.os.Looper.loop(Looper.java:317)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at android.app.ActivityThread.main(ActivityThread.java:8516)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at java.lang.reflect.Method.invoke(Native Method)
02-21 12:29:32.715 31846 31846 E AndroidRuntime:    at com.android.internal.os.RuntimeI

Edit: @patzly Do you want a video that shows the steps to reproduce?

patzly commented 4 months ago

@YoMamasNerd That's good to hear :D I've built a new nightly build with a small change, can you please test it?

YoMamasNerd commented 4 months ago

I'm using the mlkit version. Just in case it matters

--------- beginning of crash
02-21 13:51:57.663 20624 20624 E AndroidRuntime: FATAL EXCEPTION: main
02-21 13:51:57.663 20624 20624 E AndroidRuntime: Process: xyz.zedler.patrick.grocy.nightly.debug, PID: 20624
02-21 13:51:57.663 20624 20624 E AndroidRuntime: java.lang.NullPointerException: Attempt to invoke virtual method 'float androidx.core.view.WindowInsetsAnimationCompat.getInterpolatedFraction()' on a null object reference
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at xyz.zedler.patrick.grocy.util.UiUtil$1.onProgress(UiUtil.java:334)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at androidx.core.view.WindowInsetsAnimationCompat$Impl30$ProxyCallback.onProgress(WindowInsetsAnimationCompat.java:1072)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at android.view.View.dispatchWindowInsetsAnimationProgress(View.java:12173)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7624)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7630)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7630)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7630)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7630)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at android.view.ViewGroup.dispatchWindowInsetsAnimationProgress(ViewGroup.java:7630)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at android.view.ViewRootInsetsControllerHost.dispatchWindowInsetsAnimationProgress(ViewRootInsetsControllerHost.java:108)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at android.view.InsetsController.lambda$new$3(InsetsController.java:818)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at android.view.InsetsController.$r8$lambda$meqKUiuVHZJFS86fhQQzBBmdABw(Unknown Source:0)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at android.view.InsetsController$$ExternalSyntheticLambda10.run(D8$$SyntheticClass:0)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1406)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1415)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at android.view.Choreographer.doCallbacks(Choreographer.java:1015)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at android.view.Choreographer.doFrame(Choreographer.java:942)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:1389)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at android.os.Handler.handleCallback(Handler.java:959)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at android.os.Handler.dispatchMessage(Handler.java:100)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at android.os.Looper.loopOnce(Looper.java:232)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at android.os.Looper.loop(Looper.java:317)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at android.app.ActivityThread.main(ActivityThread.java:8516)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at java.lang.reflect.Method.invoke(Native Method)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:552)
02-21 13:51:57.663 20624 20624 E AndroidRuntime:    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:878)
patzly commented 4 months ago

@YoMamasNerd Oh sorry! Please test the master nightly, I haven't merged it yet :)

YoMamasNerd commented 4 months ago

No issues with the master version. I don't know however if the bug would have been reproducible if I would have used the master version from the start. Sind I used the mlkit version for the initial test..

patzly commented 4 months ago

@YoMamasNerd That's perfect! The last fix was important, else you would had another exception in the crashlog so all good now :)