Demux errors when pulling youtube audio
I'm using pafy and vlc to pull down music off of a youtube video.
Example of a particular URL causing problems:
import pafy, vlc
instance = vlc.Instance() player = instance.media_player_new()
pafy.new('https://www.youtube.com/watch?v=7jaN9B5zLzQ') best = video.getbestaudio() playurl = best.url media = instance.media_new(playurl) media.get_mrl() player.set_media(media) player.play When I issue those python commands, stderr starts kicking out the following errors:
[113c5d68] mp4 demux: Fragment sequence discontinuity detected 1 != 0 [113c58e8] mp4 demux: Fragment sequence discontinuity detected 1 != 0 [113c58e8] mp4 demux: Fragment sequence discontinuity detected 1 != 2 [113c58e8] mp4 demux: Fragment sequence discontinuity detected 1 != 2 [10ba7aa0] main decoder error: buffer deadlock prevented [113c58e8] mp4 demux: Fragment sequence discontinuity detected 1 != 2 [10ba8298] avcodec decoder: Using D3D11VA (Intel(R) UHD Graphics 620, vendor 8086(Intel), device 3ea0, revision 2) for hardware decoding [113c58e8] mp4 demux: Fragment sequence discontinuity detected 1 != 2 [113c58e8] mp4 demux: Fragment sequence discontinuity detected 1 != 2 [113c58e8] mp4 demux: Fragment sequence discontinuity detected 1 != 2 [113c58e8] mp4 demux: Fragment sequence discontinuity detected 1 != 2 [113c58e8] mp4 demux: Fragment sequence discontinuity detected 1 != 2 [113c58e8] mp4 demux: Fragment sequence discontinuity detected 1 != 2
Is there any way to either: a) fix this so the music plays as originally desired b) catch these errors so that I can skip the song instead of dealing with 4 minutes of console error reporting while the song "finishes playing"