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

Direct download link not giving the chosen format #28395

Closed
6 tasks done
Knocks83 opened this issue Mar 9, 2021 · 1 comment
Closed
6 tasks done

Direct download link not giving the chosen format #28395

Knocks83 opened this issue Mar 9, 2021 · 1 comment
Labels

Comments

@Knocks83
Copy link

Knocks83 commented Mar 9, 2021

Checklist

  • I'm reporting a broken site support issue
  • I've verified that I'm running youtube-dl version 2021.03.03
  • 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

// Getting the available formats
youtube-dl -v -F https://www.pornhub.com/view_video.php?viewkey=...

[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['-v', '-F', 'https://www.pornhub.com/view_video.php?viewkey=...']
[debug] Encodings: locale cp1252, fs mbcs, out cp850, pref cp1252
[debug] youtube-dl version 2021.01.08
[debug] Python version 3.4.4 (CPython) - Windows-10-10.0.19041
[debug] exe versions: ffmpeg 2021-01-09-git-2e2891383e-full_build-www.gyan.dev, ffprobe 2021-01-09-git-2e2891383e-full_build-www.gyan.dev
[debug] Proxy map: {}
[PornHub] ph...: Downloading pc webpage
[PornHub] ph...: Downloading m3u8 information
[PornHub] ph...: Downloading m3u8 information
[PornHub] ph...: Downloading m3u8 information
[info] Available formats for ph...:
format code  extension      resolution note
0            unknown_video  unknown
240p         mp4            240p        400k
hls-505-0    mp4            854x480     505k , avc1.64001f, 60.0fps, mp4a.40.2
hls-505-1    mp4            854x480     505k , avc1.64001f, 60.0fps, mp4a.40.2
hls-953-0    mp4            1280x720    953k , avc1.640020, 60.0fps, mp4a.40.2
hls-953-1    mp4            1280x720    953k , avc1.640020, 60.0fps, mp4a.40.2 (best)


// Trying to get the direct link with the specified format
youtube-dl -v -f mp4 --get-url https://www.pornhub.com/view_video.php?viewkey=...

[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['-v', '-f', 'mp4', '--get-url', 'https://www.pornhub.com/view_video.php?viewkey=...']
[debug] Encodings: locale cp1252, fs mbcs, out cp850, pref cp1252
[debug] youtube-dl version 2021.01.08
[debug] Python version 3.4.4 (CPython) - Windows-10-10.0.19041
[debug] exe versions: ffmpeg 2021-01-09-git-2e2891383e-full_build-www.gyan.dev, ffprobe 2021-01-09-git-2e2891383e-full_build-www.gyan.dev
[debug] Proxy map: {}
https://cv-h.phncdn.com/hls/videos/...,720P_4000K,480P_2000K,_356003342.mp4.urlset/index-f1-v1-a1.m3u8?...

Description

I need to get a direct download link from both PornHub and XNXX with a specific format but when I try giving them a format that I want it'll give me an m3u8 file instead.

Eg.
This command: youtube-dl -v -f mp4 --get-url https://www.pornhub.com/view_video.php?viewkey=...
Gives this output: https://cv-h.phncdn.com/.../index-f1-v1-a1.m3u8
The output isn't an mp4 link, even if in the formats it's listed as MP4.

@dstftw
Copy link
Collaborator

dstftw commented Mar 9, 2021

You must select proper protocol in format selection.

@dstftw dstftw closed this as completed Mar 9, 2021
@dstftw dstftw added the invalid label Mar 9, 2021
github-actions bot added a commit to hellopony/youtube-dl that referenced this issue Mar 10, 2021
* https://github.com/ytdl-org/youtube-dl:
  [shahid] fix format extraction(closes ytdl-org#28383)
  [lbry] add support for channel filters(closes ytdl-org#28385)
  [bandcamp] Extract release_timestamp
  [lbry] Extract release_timestamp (closes ytdl-org#28386)
  Introduce release_timestamp meta field (refs ytdl-org#28386)
  [pornhub] Detect flagged videos
  [pornhub] Extract formats from get_media end point (ytdl-org#28395)
This was referenced Mar 15, 2021
leshasmlesha pushed a commit to leshasmlesha/youtube-dl that referenced this issue Apr 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants