Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Can't support the subtitle" #302

Closed
emilhja opened this issue Apr 1, 2022 · 4 comments
Closed

"Can't support the subtitle" #302

emilhja opened this issue Apr 1, 2022 · 4 comments

Comments

@emilhja
Copy link

emilhja commented Apr 1, 2022

Hi,

Hi, new user here. I much appreciate your work! But I have an issue that I can only download without subtitles.

I have Windows 10, python 3.1, ffmpeg version 5.
wget is working but is horribly slow.

This generate a working video-file without subtitles.
yle-dl https://arenan.yle.fi/1-50952507 -o video1.mkv

but with following error:

[hls @ 000001f592f4f200] Can't support the subtitle(uri: https://ylekaodamd.akamaized.net/s/fhls/p/1955031/sp/195503100/serveFlavor/entryId/1_ohzum3dm/v/1/ev/16/flavorId/1_tzvz35j4/name/a.srt/index.m3u8/index.m3u8?__hdnea__=st=1648838576~exp=1648924976~acl=/s/fhls/p/1955031/sp/195503100/serveFlavor/entryId/1_ohzum3dm/v/1*~hmac=d591dfbe7574320e7fb78bca0a13db26a8bed97ae41b99d09f7e5f9a851c04a7)
Unsupported codec with id 98313 for input stream 2
[hls @ 000002df356dc000] Can't support the subtitle(uri: https://ylekaodamd.akamaized.net/s/fhls/p/1955031/sp/195503100/serveFlavor/entryId/1_ohzum3dm/v/1/ev/16/flavorId/1_tzvz35j4/name/a.srt/index.m3u8/index.m3u8?__hdnea__=st=1648838578~exp=1648924978~acl=/s/fhls/p/1955031/sp/195503100/serveFlavor/entryId/1_ohzum3dm/v/1*~hmac=2816ca303bfde61638a95fcaaba82b3053454e50c0284dd34d285124c9ac814c)

yle-dl https://arenan.yle.fi/1-50952507 -o video3.mkv -V generate following error:

DEBUG: Now trying downloader ffmpeg
Output file: video3.mkv
[hls @ 0000027f05e5f200] Can't support the subtitle(uri: https://ylekaodamd.akamaized.net/s/fhls/p/1955031/sp/195503100/serveFlavor/entryId/1_ohzum3dm/v/1/ev/16/flavorId/1_tzvz35j4/name/a.srt/index.m3u8/index.m3u8?__hdnea__=st=1648838799~exp=1648925199~acl=/s/fhls/p/1955031/sp/195503100/serveFlavor/entryId/1_ohzum3dm/v/1*~hmac=220cb514c3c218a4ffda316758f42e661cb938ac34b829ca6dc89c3167d41acf)
Unsupported codec with id 98313 for input stream 2
DEBUG: Executing:
DEBUG: ffmpeg -y -headers 'X-Forwarded-For: 91.154.84.249
' -loglevel warning -thread_queue_size 2048 -seekable 0 -strict experimental -stats -i 'https://cdnsecakmi.kaltura.com/p/1955031/sp/195503100/playManifest/entryId/1_ohzum3dm/flavorId/1_0rsrn5o3/format/applehttp/protocol/https/a.m3u8?uiConfId=43362851&referrer=aHR0cHM6Ly9hcmVuYW4ueWxlLmZpLzEtNTA5NTI1MDc=&playSessionId=11111111-1111-1111-1111-111111111111&clientTag=html5:v0.39.4' -metadata creation_time=2022-04-01T16:45:04+03:00 -map '0:p:0:v?' -map '0:p:0:a?' -scodec srt -map '0:p:0:s?' -bsf:a aac_adtstoasc -vcodec copy -acodec copy -dn file:video3.mkv
[webvtt @ 00000257ff710000] Dropping 28 duplicated subtitle events
frame= 6841 fps=697 q=-1.0 Lsize=  125750kB time=00:04:33.69 bitrate=3763.8kbits/s speed=27.9x
Stream saved to video3.mkv

Any recommendations?

Or, since wget is generating a *.srt-file. Is it possible to only download the srt with wget?

br,

@emilhja
Copy link
Author

emilhja commented Apr 1, 2022

I'm quite sure I've not done any changes but my first videos doesn't contain any subtitles.

But now my latest generated videos contain subtitles!

It still says the following, but maybe not an issue if I can see subtitles in the video?

[hls @ 0000022dbd21f200] Can't support the subtitle(uri: https://ylekaodamd.akamaized.net/s/fhls/p/1955031/sp/195503100/serveFlavor/entryId/1_ohzum3dm/v/1/ev/16/flavorId/1_tzvz35j4/name/a.srt/index.m3u8/index.m3u8?__hdnea__=st=1648840095~exp=1648926495~acl=/s/fhls/p/1955031/sp/195503100/serveFlavor/entryId/1_ohzum3dm/v/1*~hmac=08cf1b515135732699b9173596d8a2129b9ade13e98f6458563be315014c6958)
Unsupported codec with id 98313 for input stream 2
[webvtt @ 00000218673cfac0] Dropping 28 duplicated subtitle events

br,

@aajanki
Copy link
Owner

aajanki commented Apr 3, 2022

The situation with subtitles is quite confusing currently, sorry about that. Yle-dl currently always prints the two warnings "Can't support the subtitle" and "Dropping X duplicated subtitle events" but the subtitles should still get downloaded.

If you still happen to have the video3.mkv file from your first message, can you verify that it really doesn't contain subtitles? Run the command ffprobe video3.mkv. It outputs information about the content of the video file. The output should contain a section about subtitles, something like this:

  Stream #0:2(fi): Subtitle: subrip (default)
    Metadata:
      VARIANT_BITRATE : 3757872
      COMMENT         : käännöstekstitys
      ENCODER         : Lavc58.134.100 srt
      DURATION        : 00:04:24.779000000

If you see this section in the output, the subtiles were download. In that case, make sure that the correct subtitle language is selected in your video player. If you don't see the subtitles section, then it's a bug in yle-dl (or Areena).

@gunnar12
Copy link

gunnar12 commented Apr 29, 2022

Seen a lot of them subtitle complaints.

Guessed it has to do with multi-language subtitles?
yellow in my win setup, ffmpeg?? 4.3.1 uses red too, yle-dl python doesnt??
chaged video title too when svm if available?

yle also had some strange way cookie? for deciding on wiever language, browser fin/sv arena?

hmm.. long time ago "dutch" (as subtit?) was a robot audio-speaking the text??

@aajanki
Copy link
Owner

aajanki commented May 15, 2022

I have improved the support for subtitles on the master branch. There should not be warnings about subtitles on most cases anymore.

More detailed explanation: I have switched to using MPEG-DASH streams instead of HLS when possible, because ffmpeg has a better support for subtitles in DASH streams.

Low resolution streams may still result in warnings concerning subtitles, because they seem to be available only as HLS format. Even then the subtitles should work despite the warnings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants