Some YT videos won't play. mpsyt playback aborts and jumps right back to search results. Directly calling a URL on the mpsyt command line doesn't work either. Symptoms are identical to issue #826 but the cause seems different (I think #826 has been fixed in the meantime).
One possible clue: all videos that don't work show a stream size of zero Mb in the mpsyt player status line. Videos that work show a plausible size.
Example links ( these are 1st and 2nd part of the same piece):
By inserting print() statements here and there I think I ascertained that the _get_content_length function in streams.py
gets called twice (maybe that's by design)
on problem videos it returns a wrong (far too small) content-lenght header the first time it is called, and a correct lenght the second time (but for some reason the wrong value seems to be returned to _playsong in player.py instead)
Disclaimer: I'm not a developer and I had never seen Python code before, so please take the above for what it is worth.
Thanks everybody for the great work. mps-youtube is insanely cool software!
Your Environment
I am using mps-youtube version 0.2.8 development (installed with pip) -- I'm controlling it remotely via ssh.
mpsyt --version
mpsyt version : 0.2.8
notes : released 17 February 2018
pafy version : 0.5.5 (youtube-dl backend)
youtube-dl version : 2020.07.28
Python version : 3.5.2 (default, Jul 17 2020, 14:04:10)
[GCC 5.4.0 20160609]
Processor : x86_64
Machine type : x86_64
Architecture : 64bit, ELF
Platform : Linux-4.4.0-186-generic-x86_64-with-Ubuntu-16.04-xenial
sys.stdout.enc : UTF-8
default enc : utf-8
Config dir : /home/diefrosch/.config/mps-youtube
env:TERM : screen
env:SHELL : /bin/bash
env:LANG : en_US.UTF-8
env:LANGUAGE : en_US:en
Issue / Suggestion
Some YT videos won't play.
mpsyt
playback aborts and jumps right back to search results. Directly calling a URL on thempsyt
command line doesn't work either. Symptoms are identical to issue #826 but the cause seems different (I think #826 has been fixed in the meantime).One possible clue: all videos that don't work show a stream size of zero Mb in the
mpsyt
player status line. Videos that work show a plausible size.Example links ( these are 1st and 2nd part of the same piece):
By inserting
print()
statements here and there I think I ascertained that the_get_content_length
function instreams.py
content-lenght
header the first time it is called, and a correct lenght the second time (but for some reason the wrong value seems to be returned to_playsong
inplayer.py
instead)Disclaimer: I'm not a developer and I had never seen Python code before, so please take the above for what it is worth.
Thanks everybody for the great work. mps-youtube is insanely cool software!
Your Environment
I am using
mps-youtube
version 0.2.8 development (installed with pip) -- I'm controlling it remotely via ssh.mpsyt --version mpsyt version : 0.2.8 notes : released 17 February 2018 pafy version : 0.5.5 (youtube-dl backend) youtube-dl version : 2020.07.28 Python version : 3.5.2 (default, Jul 17 2020, 14:04:10) [GCC 5.4.0 20160609] Processor : x86_64 Machine type : x86_64 Architecture : 64bit, ELF Platform : Linux-4.4.0-186-generic-x86_64-with-Ubuntu-16.04-xenial sys.stdout.enc : UTF-8 default enc : utf-8 Config dir : /home/diefrosch/.config/mps-youtube env:TERM : screen env:SHELL : /bin/bash env:LANG : en_US.UTF-8 env:LANGUAGE : en_US:en
Key Value
autoplay : False
order : relevance
user_order :
max_res : 2160p
player : mpv
playerargs :
encoder : 0 [None]
notifier :
checkupdate : True
show_player_keys : True
fullscreen : False
show_status : True
always_repeat : False
columns :
ddir : /home/diefrosch/Downloads/mps
overwrite : True
show_video : False
search_music : False
window_pos :
window_size :
download_command :
lookup_metadata : True
lastfm_username :
lastfm_password :
lastfm_api_key :
lastfm_api_secret :
audio_format : auto
video_format : auto
api_key :
set_title : True
mpris : False
show_qrcode : False
history : True
input_history : True