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

[curiositystream] Downloading entirely broken due to API changes #26845

Closed
6 tasks done
Critical-Impact opened this issue Oct 9, 2020 · 4 comments
Closed
6 tasks done

Comments

@Critical-Impact
Copy link

Checklist

  • I'm reporting a broken site support issue
  • I've verified that I'm running youtube-dl version 2020.09.20
  • I've checked that all provided URLs are alive and playable in a browser
  • I've checked that all URLs and arguments with special characters are properly quoted or escaped
  • I've searched the bugtracker for similar bug reports including closed ones
  • I've read bugs section in FAQ

Verbose log

youtube-dl -c -o '%(title)s.%(ext)s' -u redacted -p redacted https://curiositystream.com/video/3818 --verbose
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['-c', '-o', '%(title)s.%(ext)s', '-u', 'PRIVATE', '-p', 'PRIVATE', 'https://curiositystream.com/video/3818', '--verbose']
[debug] Encodings: locale UTF-8, fs utf-8, out utf-8, pref UTF-8
[debug] youtube-dl version 2020.09.20
[debug] Python version 3.8.5 (CPython) - Linux-4.15.0-118-generic-x86_64-with-glibc2.27
[debug] exe versions: ffmpeg 3.4.8, ffprobe 3.4.8
[debug] Proxy map: {}
[curiositystream] Downloading JSON metadata
[curiositystream] 3818: Downloading JSON metadata
ERROR: No video formats found; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; type  youtube-dl -U  to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
Traceback (most recent call last):
  File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 797, in extract_info
    ie_result = ie.extract(url)
  File "/usr/local/bin/youtube-dl/youtube_dl/extractor/common.py", line 532, in extract
    ie_result = self._real_extract(url)
  File "/usr/local/bin/youtube-dl/youtube_dl/extractor/curiositystream.py", line 109, in _real_extract
    self._sort_formats(formats)
  File "/usr/local/bin/youtube-dl/youtube_dl/extractor/common.py", line 1359, in _sort_formats
    raise ExtractorError('No video formats found')
youtube_dl.utils.ExtractorError: No video formats found; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; type  youtube-dl -U  to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.

Description

From what I can see the API now returns a url to a MPD file instead of m3u8. There is also a V2 API that is required for accessing collections. At present accessing a url such as https://app.curiositystream.com/collections/2 via the V1 api actually refers to an entirely different set of videos.

There also appears to be a few extra headers that are required to have the API return the correct data when doing the extraction.
I've been able to make changes to a local copy of youtube-dl to fix it however I'm not 100% sure on how to structure the changes to allow access to both the V1 and V2 apis.

Happy to provide any other information about what is required to get this to work.

@october262
Copy link

your link https://curiositystream.com/video/3818 works ok for me
just do youtube-dl https://curiositystream.com/video/3818

@Critical-Impact
Copy link
Author

If you do that without providing a username/password you'll get only a sample video. Attempting to download it with a username and password will give the original error I posted.

@october262
Copy link

have you tried using the cookies option ??

@Critical-Impact
Copy link
Author

It's not a authentication problem as far as I can see. I've downloaded the source code and get the correct API responses and can even get it to download by making some modifications however it appears they've made some changes to their API that means there are now mpds(when the file to download is a .mov), a V1 and V2 api and when downloading collections sometimes those collections have collections inside them.

github-actions bot added a commit to hellopony/youtube-dl that referenced this issue Apr 7, 2021
* https://github.com/ytdl-org/youtube-dl:
  [cbssports] fix extraction(closes ytdl-org#28682)
  [jamendo] fix track extraction(closes ytdl-org#28686)
  [curiositystream] fix format extraction(closes ytdl-org#26845, closes ytdl-org#28668)
  release 2021.04.07
  [ChangeLog] Actualize [ci skip]
  [youtube] Fix videos with restricted location (closes ytdl-org#28685)
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

2 participants