Playback crashes when bluetooth is turned off
Behavior of the program I often connect an external speaker to bluetooth to do things like listen to podcasts while doing dishes, in the shower, etc. When I come back to my computer I'm often not finished and want to watch the conclusion on my laptop speakers, as the bluetooth is too loud or I've left it in the kitchen, etc. When I turn bluetooth off in Windows, the video stops playing and throws a "The media playback was aborted due to a corruption problem or because the media used features your browser did not support." error.
Expected behavior I expect the audio to switch seamlessly to the laptop's internal speaker, as happens when I watch Youtube videos on youtube.com.
To Reproduce
- Connect an external speaker to bluetooth.
- Start a video playing.
- Turn off bluetooth in Windows settings.
Link to video All
Screenshots N/A
Environment Information (please complete the following information):
- OS: Windows
- OS Version: 8.1
- FreeTube version: v0.13.2 Beta
- Installation Method (If applicable): exe
- Primary API Used: Local API
I have no idea about this topic. If someone with some experience could chip in to clarify how this could be related, I'd be very happy
Because in my mind these two things should not be connected directly, as the Bluetooth connection comes from the OS and not from our app
No other software on my machine crashes when bluetooth is turned off. It's only FreeTube.
Okay, this could be a problem with Electron itself. Could you try some electron based software, e.g. another music player? You can find a list of software over at electron: https://www.electronjs.org/apps
Going to chime in and say I'm facing a similar issue with bluetooth headphones, I'm using Museeks, which is electron based, and it's never had issues. I don't think it's electron; I think it's the video player in FreeTube.
If I disconnect the headphones after I pause a video, trying to resume the video doesn't work. FreeTube's video player expects there to always be an audio device, when there are none the video refuses to play another frame until the video is paused, the headphones reconnected, and then the video is resumed. Sometimes attempting to resume the video after reconnecting the audio device causes the video to fail like the person above saw, however, I've not had this personally happen for a while.
What I think's happening to Tiltowait2 is that FreeTube's video player doesn't seek out new audio devices when the current one is disconnected, even if another audio device was present the entire time, it just keeps wanting the original device until it comes back or FreeTube is refreshed with the laptop's audio device being used instead.
I'm using Arch Linux (Pipewire) and they're using Windows, so I don't think the audio backend for our OS's are causing this, hence why I think the video player is at fault here.
Okay thanks for the info. So we basically have to look for a solution. Could be possible that VideoJS itself provides a possibility, if it is the player.
Correction,
In Museeks, disconnecting bluetooth headphones while a song was paused causes Museeks to not send any audio to the headphones when unpaused, electron could still be the cause or it's just that Museek and FreeTube treat audio devices similarly. My previous attempts involved removing and adding the headphones before a song was played hence why this issue never occured before.
Missing audio devices causing the video to crash is still likely an issue with FreeTube's video player though.
This still happens in v0.16.0 Beta. :(
This issue is stale because it has been open 28 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.