Brad Flood
Brad Flood
Looking at all the older issues related to this, it appears this issue should be fixed in `4.0.1`, but it's not for me. Still getting this crash report several times...
Stack trace from BugSnag: ``` ActivityThread.java:4880 android.app.ActivityThread.handleServiceArgs Unknown android.app.ActivityThread.-$$Nest$mhandleServiceArgs ActivityThread.java:2314 android.app.ActivityThread$H.handleMessage Handler.java:106 android.os.Handler.dispatchMessage Looper.java:205 android.os.Looper.loopOnce Looper.java:294 android.os.Looper.loop ActivityThread.java:8248 android.app.ActivityThread.main Method.java:-2 java.lang.reflect.Method.invoke RuntimeInit.java:552 com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run ZygoteInit.java:971 com.android.internal.os.ZygoteInit.main Caused By: android.app.ForegroundServiceStartNotAllowedException · Service.startForeground()...
Great info thanks @lovegaoshi I'm going to go with your `1.` commit for now and see if it helps my crashes :)
`patch-package` patch here if anyone else wants to try it ``` diff --git a/node_modules/react-native-track-player/android/src/main/java/com/doublesymmetry/trackplayer/service/MusicService.kt b/node_modules/react-native-track-player/android/src/main/java/com/doublesymmetry/trackplayer/service/MusicService.kt index 9d6d869..a0a150e 100644 --- a/node_modules/react-native-track-player/android/src/main/java/com/doublesymmetry/trackplayer/service/MusicService.kt +++ b/node_modules/react-native-track-player/android/src/main/java/com/doublesymmetry/trackplayer/service/MusicService.kt @@ -587,9 +587,10 @@ class MusicService : HeadlessJsTaskService()...
 > do NOT kill foreground service like https://github.com/lovegaoshi/react-native-track-player/commit/9afe35b163c84bf69ba484699dc8aac94dfc00cb Unfortunately this did not change things for me in prod :( I'll try your wake lock fix and let you know...
I'm definitely getting LESS of this crash report since trialing the patch fix above. But yes I agree there also appears to be some remaining crashes related to a race...
Hi @singhiam, I recommend switching over to https://github.com/doublesymmetry/react-native-track-player
This can be closed then, yea?
Nice mate!
I'm having this same issue with SublimeText3