mps-youtube / yewtube

yewtube, forked from mps-youtube , is a Terminal based YouTube player and downloader. No Youtube API key required.
GNU General Public License v3.0
8.07k stars 648 forks source link

Failed to recognize file format. #1000

Closed archagy closed 1 year ago

archagy commented 5 years ago

In almost every song that I tried to reproduce I got the error of Failed to recognize format.

Issue / Suggestion

I run with the debug param and it's show this link when the error occurs.

    RalphReal - All For | No Copyright Music [02:59]                                                                                                                                                        
Playing: https://manifest.googlevideo.com/api/manifest/dash/expire/1563940062/ei/foA3XauYE4v-Nq-_h4gL/ip/2806%3A270%3A0%3A3%3A1c0%3A%3A2e/id/2f76ddd78a728e6d/source/youtube/requiressl/yes/playback_host/r5
---sn-q4flrn7y.googlevideo.com/mm/31%2C26/mn/sn-q4flrn7y%2Csn-a5mlrn7r/ms/au%2Conr/mv/m/mvi/4/pl/34/tx/23824524/txs/23824516%2C23824517%2C23824518%2C23824519%2C23824520%2C23824521%2C23824522%2C23824523%2C
23824524%2C23824525%2C23824526/hfr/all/as/fmp4_audio_clear%2Cwebm_audio_clear%2Cwebm2_audio_clear%2Cfmp4_sd_hd_clear%2Cwebm2_sd_hd_clear/initcwndbps/2291250/mt/1563918345/fvip/5/itag/0/sparams/expire%2Cei
%2Cip%2Cid%2Csource%2Crequiressl%2Ctx%2Ctxs%2Chfr%2Cas%2Citag/sig/ALgxI2wwRQIhAL43O18i5z6lreiiQ8CKZD4YaYMm-MjHdmx2DNHIGEWYAiAN2Z7OgTiL6W4U-Oi5clzqrpHpgZMJO8OsywQ0bYwwhg%3D%3D/lsparams/playback_host%2Cmm%2
Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps/lsig/AHylml4wRgIhAOjT4mV9k3OwX87S7LYirrwTx1tMmHIs6xdmxUOJAqvlAiEAsNTfmcKUWi1mYdcIzxVuvgrmkHZAHUFN003HTjAAXvg%3D                                                      
Failed to recognize file format. 

When it works well I got this output.

    TRADITIONAL - No Copyright Music [01:52]
Playing: https://r4---sn-q4f7sn7z.googlevideo.com/videoplayback?expire=1563940063&ei=f4A3XanOEZffNsqhnbAL&ip=2806%3A270%3A0%3A3%3A1c0%3A%3A2e&id=o-AAm0pFclooa-esJn-u7O7kL2H6zbmALdbzLbpcT8tiZj&itag=251&sou
rce=youtube&requiressl=yes&mm=31%2C26&mn=sn-q4f7sn7z%2Csn-a5mekn7d&ms=au%2Conr&mv=m&mvi=3&pl=34&initcwndbps=2291250&mime=audio%2Fwebm&gir=yes&clen=2436865&dur=111.361&lmt=1563912394484488&mt=1563918345&fv
ip=4&keepalive=yes&beids=9466586&c=WEB&txp=6201222&sparams=expire%2Cei%2Cip%2Cid%2Citag%2Csource%2Crequiressl%2Cmime%2Cgir%2Cclen%2Cdur%2Clmt&sig=ALgxI2wwRQIgUeELu4yyR2k3i56SK1-LSZS1WWmwKStDhMhxV8tf1QcCIQ
DbsGxMYSACEIvoR7mXDwYws30QAibrne2P0ODHHyctLw%3D%3D&lsparams=mm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=AHylml4wRQIhAO9dZ9m7q4sb0BzliXWHS1A_Pm5gRQ7cqOJQB1mhsPIXAiBpPFO_8FOrgI0qTSRpHM9DQO1y0OqQqeevCnIO
4EvGkA%3D%3D&ratebypass=yes
 (+) Audio --aid=1 --alang=eng (*) (opus 2ch 48000Hz)
AO: [coreaudio] 48000Hz stereo 2ch floatp

Your Environment

--

mpsyt version : 0.2.8 notes : released 17 February 2018 pafy version : 0.5.4 (youtube-dl backend) youtube-dl version : 2019.07.16 Python version : 3.7.3 (default, May 21 2019, 12:11:11) [Clang 10.0.1 (clang-1001.0.46.3)] Processor : i386 Machine type : x86_64 Architecture : 64bit, Platform : Darwin-18.6.0-x86_64-i386-64bit sys.stdout.enc : UTF-8 default enc : utf-8 Config dir : ~/.config/mps-youtube env:TERM : screen-256color env:SHELL : /bin/bash could not load MPRIS interface. missing libraries.

Hugal31 commented 4 years ago

Same here. It seems to be because mplayer and mpv doesn't support the DASH format, mainly because ffmpeg doesn't support it (at least before version 3.4 if I understand correctly).

youtube-dl has a command-line argument --youtube-skip-dash-manifest to avoid relying on Dash format. It would be nice to a similar option to mps-youtube.