]>
Raphaƫl G. Git Repositories - youtubedl/blob - youtube_dl/extractor/nerdcubed.py
2 from __future__
import unicode_literals
6 from .common
import InfoExtractor
9 class NerdCubedFeedIE(InfoExtractor
):
10 _VALID_URL
= r
'https?://(?:www\.)?nerdcubed\.co\.uk/feed\.json'
12 'url': 'http://www.nerdcubed.co.uk/feed.json',
14 'id': 'nerdcubed-feed',
15 'title': 'nerdcubed.co.uk feed',
17 'playlist_mincount': 1300,
20 def _real_extract(self
, url
):
21 feed
= self
._download
_json
(url
, url
, 'Downloading NerdCubed JSON feed')
25 'title': feed_entry
['title'],
26 'uploader': feed_entry
['source']['name'] if feed_entry
['source'] else None,
27 'upload_date': datetime
.datetime
.strptime(feed_entry
['date'], '%Y-%m-%d').strftime('%Y%m%d'),
28 'url': 'http://www.youtube.com/watch?v=' + feed_entry
['youtube_id'],
29 } for feed_entry
in feed
]
33 'title': 'nerdcubed.co.uk feed',
34 'id': 'nerdcubed-feed',