ytdl-org / youtube-dl

Command-line program to download videos from YouTube.com and other video sites
http://ytdl-org.github.io/youtube-dl/
The Unlicense
132.28k stars 10.03k forks source link

STRETCHIT #32041

Open slavakurilyak opened 1 year ago

slavakurilyak commented 1 year ago

Checklist

Example URLs

Description

STRETCHIT uses Vimeo for its classes.

Running youtube-dl -v https://web.stretchitapp.com/app/packages/4/lesson/174\?event_id\=15222708 gives:

youtube-dl -v https://web.stretchitapp.com/app/packages/4/lesson/174\?event_id\=15222708
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['-v', 'https://web.stretchitapp.com/app/packages/4/lesson/174?event_id=15222708']
[debug] Encodings: locale UTF-8, fs utf-8, out utf-8, pref UTF-8
[debug] youtube-dl version 2021.12.17
[debug] Python version 3.11.3 (CPython) - macOS-12.6.3-x86_64-i386-64bit
[debug] exe versions: ffmpeg 5.1.2, ffprobe 5.1.2, rtmpdump 2.4
[debug] Proxy map: {}
[generic] 174?event_id=15222708: Requesting header
WARNING: Falling back on generic information extractor.
[generic] 174?event_id=15222708: Downloading webpage
[generic] 174?event_id=15222708: Extracting information
ERROR: Unsupported URL: https://web.stretchitapp.com/app/packages/4/lesson/174?event_id=15222708
Traceback (most recent call last):
  File "/usr/local/lib/python3.11/site-packages/youtube_dl/YoutubeDL.py", line 815, in wrapper
    return func(self, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/youtube_dl/YoutubeDL.py", line 836, in __extract_info
    ie_result = ie.extract(url)
                ^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/youtube_dl/extractor/common.py", line 534, in extract
    ie_result = self._real_extract(url)
                ^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/youtube_dl/extractor/generic.py", line 3489, in _real_extract
    raise UnsupportedError(url)
youtube_dl.utils.UnsupportedError: Unsupported URL: https://web.stretchitapp.com/app/packages/4/lesson/174?event_id=15222708
dirkf commented 1 year ago

This site is a JS application. The non-JS page seen by yt-dl doesn't include the Vimeo links, so there's no chance that yt-dl can find them with its generic extractor.

By tracing browser traffic and/or inspecting the site JS, it might be possible to emulate the site JS in an extractor. It may also be necessary to pass some site-specific data through to the Vimeo extractor, as with the Dropout extractor.

dirkf commented 1 year ago

Also: https://github.com/yt-dlp/yt-dlp/issues/6805