gateship-one / odyssey

Odyssey music player
GNU General Public License v3.0
232 stars 39 forks source link

Fatal exception in the master branch code #122

Closed dankan1890 closed 6 years ago

dankan1890 commented 6 years ago

The issue occurs almost randomly.

E/AndroidRuntime: FATAL EXCEPTION: main
                  Process: org.gateshipone.odyssey, PID: 13247
                  java.lang.RuntimeException: Error receiving broadcast Intent { act=org.gateshipone.odyssey.newtrackinfo flg=0x10 pkg=org.gateshipone.odyssey (has extras) } in org.gateshipone.odyssey.views.NowPlayingView$NowPlayingReceiver@a9607
                      at android.app.LoadedApk$ReceiverDispatcher$Args.run(LoadedApk.java:1132)
                      at android.os.Handler.handleCallback(Handler.java:751)
                      at android.os.Handler.dispatchMessage(Handler.java:95)
                      at android.os.Looper.loop(Looper.java:154)
                      at android.app.ActivityThread.main(ActivityThread.java:6077)
                      at java.lang.reflect.Method.invoke(Native Method)
                      at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:866)
                      at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:756)
                   Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'void org.gateshipone.odyssey.adapter.CurrentPlaylistAdapter.updateState(org.gateshipone.odyssey.playbackservice.NowPlayingInformation)' on a null object reference
                      at org.gateshipone.odyssey.views.CurrentPlaylistView.playlistChanged(CurrentPlaylistView.java:124)
                      at org.gateshipone.odyssey.views.NowPlayingView.updateStatus(NowPlayingView.java:1087)
                      at org.gateshipone.odyssey.views.NowPlayingView.access$2300(NowPlayingView.java:80)
                      at org.gateshipone.odyssey.views.NowPlayingView$NowPlayingReceiver.lambda$onReceive$0$NowPlayingView$NowPlayingReceiver(NowPlayingView.java:1358)
                      at org.gateshipone.odyssey.views.NowPlayingView$NowPlayingReceiver$$Lambda$0.run(Unknown Source)
                      at android.app.Activity.runOnUiThread(Activity.java:5849)
                      at org.gateshipone.odyssey.views.NowPlayingView$NowPlayingReceiver.onReceive(NowPlayingView.java:1356)
                      at android.app.LoadedApk$ReceiverDispatcher$Args.run(LoadedApk.java:1122)
                      at android.os.Handler.handleCallback(Handler.java:751) 
                      at android.os.Handler.dispatchMessage(Handler.java:95) 
                      at android.os.Looper.loop(Looper.java:154) 
                      at android.app.ActivityThread.main(ActivityThread.java:6077) 
                      at java.lang.reflect.Method.invoke(Native Method) 
                      at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:866) 
                      at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:756) 
djselbeck commented 6 years ago

Thanks for reporting this. We also noticed the problems and are fully aware of them. We made some changes to the handling of the serviceconnection between the UI and the PlaybackService and a few safety checks are still missing.

We'll fix this in time.

Also we do not encourage users to use the master branch as we tend to make changes that can break something which is unavoidable for some changes ;).

dankan1890 commented 6 years ago

I'm aware that the master branch is to develop and that cannot be stable, my only wanted to make a report in case you are not experiencing this issue ;)

Thanks for the answer and for the great app (I think the only one that has many features and no dependence on libraries outside the Android project) 👍