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 download private playlist, even with username and password provided. #1757

Closed
johnnynoone opened this issue Nov 12, 2013 · 6 comments
Closed
Assignees

Comments

@johnnynoone
Copy link

@johnnynoone johnnynoone commented Nov 12, 2013

As in title. Output:

[debug] System config: []
[debug] User config: []
[debug] Command-line args: ['--verbose', '--username', '<PRIVATE>', '--password', '<PRIVATE>', '--simulate', 'http://www.youtube.com/playlist?list=PLBP8VMRokh1MLEHEAcMlze-iLSqQy_Yud']
[debug] youtube-dl version 2013.11.11
[debug] Python version 2.7.5+ - Linux-3.11.0-12-generic-x86_64-with-Ubuntu-13.10-saucy
[debug] Proxy map: {}
[youtube:playlist] PLBP8VMRokh1MLEHEAcMlze-iLSqQy_Yud: Downloading page #1
ERROR: Unable to download webpage: HTTP Error 403: Forbidden; please report this issue on https://yt-dl.org/bug . Be sure to call youtube-dl with the --verbose flag and include its complete output. Make sure you are using the latest version; type  youtube-dl -U  to update.
  File "/usr/local/bin/youtube-dl/youtube_dl/extractor/common.py", line 155, in _request_webpage
    return compat_urllib_request.urlopen(url_or_request)
  File "/usr/lib/python2.7/urllib2.py", line 127, in urlopen
    return _opener.open(url, data, timeout)
  File "/usr/lib/python2.7/urllib2.py", line 410, in open
    response = meth(req, response)
  File "/usr/lib/python2.7/urllib2.py", line 523, in http_response
    'http', request, response, code, msg, hdrs)
  File "/usr/lib/python2.7/urllib2.py", line 448, in error
    return self._call_chain(*args)
  File "/usr/lib/python2.7/urllib2.py", line 382, in _call_chain
    result = func(*args)
  File "/usr/lib/python2.7/urllib2.py", line 531, in http_error_default
    raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)

Without --simulate it shows the same error. Simulation of downloading public playlist while logging in works.

@jaimeMF
Copy link
Collaborator

@jaimeMF jaimeMF commented Nov 13, 2013

We currently use the gdata api for downloading the playlists, we can't get private playlists. That would require solving #1508.
I'm closing it then, but thanks for the report.

@jaimeMF
Copy link
Collaborator

@jaimeMF jaimeMF commented Nov 13, 2013

I'll better mark it as closed once we merge the fix.

@jaimeMF jaimeMF reopened this Nov 13, 2013
@johnnynoone
Copy link
Author

@johnnynoone johnnynoone commented Nov 13, 2013

For one-time download I could make it unlisted, download it and then make it private again, but I thought about making bash script to sync my playlists to my PC.

(BTW I've read about --download-archive , but it sounds like it puts files into an archive, is there something else I could use for syncing? I mean --skip-existing or something like this. Also writing video descriptions somewhere would be nice too, but it's probably out of scope for this project - descriptions are not videos.)

@ghost ghost assigned jaimeMF Nov 13, 2013
@jaimeMF jaimeMF closed this in 880e1c5 Nov 22, 2013
@phihag
Copy link
Contributor

@phihag phihag commented Nov 22, 2013

@johnnynoone Since youtube-dl 2013.11.22.1, this should work. Type sudo youtube-dl -U to update.

By default, youtube-dl will not redownload already existing files. If you read the description of --download-archive, you'll see that that can be used to store the video IDs in a central file and prevent redownloading. If not now, than in future releases this will speed up downloads of large playlists where many files exists significantly. (It's a little bit complicated because of the possible filename patterns otherwise and therefore slower without --download-archive)

To write the video descriptions along with the video files, simply use --write-description. In general, have a look at the output of youtube-dl --help if you want to know more about the options. If you don't understand the documentation, please drop us a hint so we can fix it. Thanks!

@johnnynoone
Copy link
Author

@johnnynoone johnnynoone commented Dec 1, 2013

OK, it works.

About option descriptions...
--download-archive's description should say something like "Download only videos not listed in the archive file." instead of "Download only videos not present in the archive file."
--abort-on-error's description should say that this is the default.

Also in Youtube's descriptions if there are long links, they are ellipsized. It would be nice if ellipsized ones were replaced by full URIs, but perhaps it would be hard to code. (Differentiation between normal links and time links like 0:00, resolving Youtube redirect pages, etc.)

I would file separate bugs, but I don't have time right now.

phihag added a commit that referenced this issue Dec 3, 2013
@phihag
Copy link
Contributor

@phihag phihag commented Dec 3, 2013

Thanks, I've changed the description of --download-archive. The default of youtube-dl is whatever is sensible, so we reserve the right to switch on and off the --ignore-errors / --abort-on-errors handling at any time. Feel free to create a new issue for the improvements to the description.

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
3 participants
You can’t perform that action at this time.