UNKNOWN
Project description
Vidscraper is a library for retrieving information about videos from various sources – video feeds, APIs, page scrapes – combining it, and presenting it in a unified manner, all as efficiently as possible.
Vidscraper comes with built-in support for popular video sites like blip, vimeo, ustream, and youtube, as well support for generic RSS feeds with feedparser.
Quick example
>>> import vidscraper >>> video = vidscraper.auto_scrape('http://www.youtube.com/watch?v=PMpu8jH1LE8') >>> video.title u"The Magic Roundabout - Ermintrude's Folly" >>> video.description u"Ermintrude's been at the poppies again, but it's Dougal who ends up high as a kite!" >>> video.user u'nickhirst999' >>> video.guid 'http://gdata.youtube.com/feeds/api/videos/PMpu8jH1LE8'
Command line
vidscraper also comes with a command line utility allowing you to get video metadata from the command line. The example above could look like this:
$ vidscraper video http://www.youtube.com/watch?v=PMpu8jH1LE8 \
--fields=title,description,user,guid
Scraping http://www.youtube.com/watch?v=PMpu8jH1LE8...
{
"description": "Ermintrude's been at the poppies again, but it's Dougal who ends up high as a kite!",
"fields": [
"title",
"description",
"user",
"guid"
],
"guid": "http://gdata.youtube.com/feeds/api/videos/PMpu8jH1LE8",
"title": "The Magic Roundabout - Ermintrude's Folly",
"url": "http://www.youtube.com/watch?v=PMpu8jH1LE8",
"user": "nickhirst999"
}
Additional links
- docs:
- irc:
#vidscraper on irc.freenode.net
- build status:
Requirements
Python 2.6+
BeautifulSoup 4.0.2+
feedparser 5.1.2+
python-requests 0.13.0+ (But less than 1.0.0!)
Optional
requests-oauth 0.4.1+ (for some APIs *cough* Vimeo searching *cough* which require authentication)
lxml 2.3.4+ (recommended for BeautifulSoup; assumed parser for test results.)
unittest2 0.5.1+ (for tests)
mock 0.8.0+ (for tests)
tox 1.4.2+ (for tests)
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file vidscraper-1.0.1.tar.gz
.
File metadata
- Download URL: vidscraper-1.0.1.tar.gz
- Upload date:
- Size: 48.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | d35f8a17cd559564e4060217baf7151f11f23dbe27e802dedce79a5a8d25f681 |
|
MD5 | d8cc521ce4f55f055961b4792104da00 |
|
BLAKE2b-256 | 2769710b4cb31b144f7bbbc556c10ad94a0a02608b21859e88cb45f8f72125c1 |