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

[yuvutu] Add new extractor #10869

Closed
wants to merge 6 commits into from
Closed

[yuvutu] Add new extractor #10869

wants to merge 6 commits into from

Conversation

drguildo
Copy link
Contributor

@drguildo drguildo commented Oct 7, 2016

Before submitting a pull request make sure you have:

In order to be accepted and merged into youtube-dl each piece of code must be in public domain or released under Unlicense. Check one of the following options:

  • I am the original author of this code and I am willing to release it under Unlicense
  • I am not the original author of this code but it is in public domain or released under Unlicense (provide reliable evidence)

What is the purpose of your pull request?

  • Bug fix
  • Improvement
  • New extractor
  • New feature

Added an extractor for Yuvutu.

$ python test\test_download.py TestDownload.test_Yuvutu
[Yuvutu] 330: Downloading webpage
[Yuvutu] 330: Downloading webpage
[info] Writing video description metadata as JSON to: 330.info.json
[debug] Invoking downloader on 'http://cdn.yuvutu.com/prod/streams/330_carnalbliss.flv?nvb=20161007102807&nva=20161007202807&hash=0083873be750ddaf1b3f9'
[download] Destination: 330.flv
[download] 100% of 10.00KiB in 00:00
.
----------------------------------------------------------------------
Ran 1 test in 1.684s

OK

_title_regex = r"class=[\"']video-title-content[\"']>.+?>(.+?)<"
_thumbnail_regex = r"itemprop=[\"']thumbnailURL[\"']\s+content=[\"'](.+?)[\"']"
_embed_regex = r"[\"'](\/embed_video\.php.+?)[\"']"
_video_regex = r"file:\s*[\"']([^\s]+)[\"']"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These should be moved at places of their usage since they only used once.

@drguildo
Copy link
Contributor Author

$ python test\test_download.py TestDownload.test_YuvutuUser
[YuvutuUser] 1072966: Downloading user page 1
[YuvutuUser] 1072966: Downloading user page 2
[YuvutuUser] 1072966: Downloading user page 3
[download] Downloading playlist: 1072966
[YuvutuUser] playlist 1072966: Collected 90 video ids (downloading 90 of them)
[download] Downloading video 1 of 90
--✂--
[download] Downloading video 90 of 90
[download] Finished downloading playlist: 1072966
.
----------------------------------------------------------------------
Ran 1 test in 3.354s

OK

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

Successfully merging this pull request may close these issues.

None yet

2 participants