Every single request is giving a Result.Success.
flutter_exoplayer: ^0.6.1
final Result result = await _audioPlayer.play(
url,
repeatMode: true,
respectAudioFocus: false,
playerMode: PlayerMode.BACKGROUND,
);
I can put in a bad URL but it still gives Result.Success.
I've used this library in the past without issues so not sure what is going on now.
Using this
AudioPlayer.logEnabled = true;
doesn't provide anything useful.
I do see exoplayer exceptions thrown and caught in the logs so I can't even put a try catch around the code to catch errors.
I added a listener in initaudioplayer() but this is not even trapped errors.
void _initAudioPlayer() {
_audioPlayer = AudioPlayer();
_playerErrorSubscription = _audioPlayer.onPlayerError.listen((msg) {
print('audioPlayer ERROR : $msg');
playerState.value = PlayerState.STOPPED;
_position = Duration(seconds: 0);
})
Can't see how I will be able to use this library without any way to trap error conditions.