react-native-track-player
react-native-track-player copied to clipboard
Stop Listener is not called
Describe the Bug When we played any songs with more than 20 minutes length, Device goes to locked mode and music is playing but when track is completed stop listener code is not called.
this.onMeditationComplete = TrackPlayer.addEventListener(
'playback-queue-ended', {
})
Steps To Reproduce
- Play any song more than 20 min length
- Lock the device and wait for complete the track
- Unlock the device when track is complete
- Check the stop listener when track is completed
~I encountered this problem on a real android device, targetsdk and os android 14 if that matters; I suspected it has to do with the doze mode and app in idle mode, but when I force idle and set-inactive of my app on an emulator the activity will get killed eventually. unsure how to reliably reproduce this. can't reproduce in emulator.~
~My workaround in mind is because I monitor the playback progress to achieve a fade out effect, I will do an if check if song is at queue's last index and manually emit playback-queue-ended this way. ~
my problem is completely different; can't reproduce what ur describing.
This issue is stale because it has been open 90 days with no activity. Remove stale label or comment or this will be closed in 7 days.
This issue was closed because it has been stalled for 7 days with no activity.