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

[Atresplayer] Unable to download JSON metadata: HTTP Error 404 #24026

Open
josergdev opened this issue Feb 11, 2020 · 2 comments
Open

[Atresplayer] Unable to download JSON metadata: HTTP Error 404 #24026

josergdev opened this issue Feb 11, 2020 · 2 comments

Comments

@josergdev
Copy link

@josergdev josergdev commented Feb 11, 2020

Checklist

  • I'm reporting a broken site support
  • I've verified that I'm running youtube-dl version 2020.01.24
  • 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 issues including closed ones

Verbose log

[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['https://www.atresplayer.com/lasexta/programas/lo-de-evole/temporada-1/junqueras_5e3d3d0f7ed1a809591305d5/', '-u', 'PRIVATE', '-p', 'PRIVATE', '--verbose']
[debug] Encodings: locale cp1252, fs utf-8, out utf-8, pref cp1252
[debug] youtube-dl version 2020.01.24
[debug] Python version 3.8.1 (CPython) - Windows-10-10.0.18362-SP0
[debug] exe versions: ffmpeg 4.2.1, ffprobe 4.2.1, phantomjs 2.1.1
[debug] Proxy map: {}
[AtresPlayer] Downloading login page
[AtresPlayer] Logging in
[AtresPlayer] Following Target URL
[AtresPlayer] 5e3d3d0f7ed1a809591305d5: Downloading JSON metadata
ERROR: Unable to download JSON metadata: HTTP Error 404: Not Found (caused by <HTTPError 404: 'Not Found'>); please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see  https://yt-dl.org/update  on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
  File "c:\users\joser\appdata\local\programs\python\python38-32\lib\site-packages\youtube_dl\extractor\common.py", line 627, in _request_webpage
    return self._downloader.urlopen(url_or_request)
  File "c:\users\joser\appdata\local\programs\python\python38-32\lib\site-packages\youtube_dl\YoutubeDL.py", line 2237, in urlopen
    return self._opener.open(req, timeout=self._socket_timeout)
  File "c:\users\joser\appdata\local\programs\python\python38-32\lib\urllib\request.py", line 531, in open
    response = meth(req, response)
  File "c:\users\joser\appdata\local\programs\python\python38-32\lib\urllib\request.py", line 640, in http_response
    response = self.parent.error(
  File "c:\users\joser\appdata\local\programs\python\python38-32\lib\urllib\request.py", line 569, in error
    return self._call_chain(*args)
  File "c:\users\joser\appdata\local\programs\python\python38-32\lib\urllib\request.py", line 502, in _call_chain
    result = func(*args)
  File "c:\users\joser\appdata\local\programs\python\python38-32\lib\urllib\request.py", line 649, in http_error_default
    raise HTTPError(req.full_url, code, msg, hdrs, fp)

Description

The plugin has stopped working for all resources. The api seems to have not changed.
Edit:
The new json data endpoint is https://api.atresplayer.com/player/v1/episode/5e3d3d0f7ed1a809591305d5

@josergdev
Copy link
Author

@josergdev josergdev commented Feb 12, 2020

Apparently there are more changes.
Atresplayer now distinguishes between two types of videos: episodes and videos.

  • Episodes
    • Episodes
  • Videos
    • Videos
    • Clips

First you have to know if a link is an episode or a video. The html source gives you the answer. The first script tag contains a json with the content type:
"@type":"TVEpisode"

<script type="application/ld+json">{"@context":"http:\u002F\u002Fschema.org","@type":"TVEpisode","@id":"https:\u002F\u002Fwww.atresplayer.com\u002Flasexta\u002Fprogramas\u002Flo-  ........................... </script>

or
"@type":"VideoObject"

<script type="application/ld+json">{"@context":"http:\u002F\u002Fschema.org","@type":"VideoObject","name":"ARUSITYS - Alfonso Arús llega a las mañanas de laSexta: ....................... </script>

Now you can make a request to get one of these two endpoints depending on the type of content:
https://api.atresplayer.com/player/v1/episode/<vod_id>
https://api.atresplayer.com/player/v1/video/<vod_id>

@jEsuSdA
Copy link

@jEsuSdA jEsuSdA commented Apr 13, 2020

@josergdev Thank you very much!! thanks!!!!

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

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.