about summary refs log tree commit diff
path: root/youtube_dl/extractor/franceinter.py
diff options
context:
space:
mode:
authorSergey M․ <dstftw@gmail.com>2016-09-17 15:44:37 +0700
committerSergey M․ <dstftw@gmail.com>2016-09-17 15:44:37 +0700
commitc51a7f0b2f2454bfe0b53f9d79567b3210e015b3 (patch)
treee6af0fd276ceeb3520df00921cae7b5f2c1cefe5 /youtube_dl/extractor/franceinter.py
parentd05ef09d9d94fa70335af5fbaab385b37b16d705 (diff)
downloadyoutube-dl-c51a7f0b2f2454bfe0b53f9d79567b3210e015b3.tar.gz
youtube-dl-c51a7f0b2f2454bfe0b53f9d79567b3210e015b3.tar.xz
youtube-dl-c51a7f0b2f2454bfe0b53f9d79567b3210e015b3.zip
[franceinter] Fix upload date extraction
Diffstat (limited to 'youtube_dl/extractor/franceinter.py')
-rw-r--r--youtube_dl/extractor/franceinter.py14
1 files changed, 7 insertions, 7 deletions
diff --git a/youtube_dl/extractor/franceinter.py b/youtube_dl/extractor/franceinter.py
index 1a1232ade..707b9e00d 100644
--- a/youtube_dl/extractor/franceinter.py
+++ b/youtube_dl/extractor/franceinter.py
@@ -2,7 +2,6 @@
 from __future__ import unicode_literals
 
 from .common import InfoExtractor
-from ..compat import compat_str
 from ..utils import month_by_name
 
 
@@ -10,14 +9,14 @@ class FranceInterIE(InfoExtractor):
     _VALID_URL = r'https?://(?:www\.)?franceinter\.fr/emissions/(?P<id>[^?#]+)'
 
     _TEST = {
-        'url': 'https://www.franceinter.fr/emissions/la-tete-au-carre/la-tete-au-carre-14-septembre-2016',
-        'md5': '4e3aeb58fe0e83d7b0581fa213c409d0',
+        'url': 'https://www.franceinter.fr/emissions/affaires-sensibles/affaires-sensibles-07-septembre-2016',
+        'md5': '9e54d7bdb6fdc02a841007f8a975c094',
         'info_dict': {
-            'id': 'la-tete-au-carre/la-tete-au-carre-14-septembre-2016',
+            'id': 'affaires-sensibles/affaires-sensibles-07-septembre-2016',
             'ext': 'mp3',
-            'title': 'Et si les rêves pouvaient nous aider à agir dans notre vie quotidienne ?',
-            'description': 'md5:a245dd62cf5bf51de915f8d9956d180a',
-            'upload_date': '20160914',
+            'title': 'Affaire Cahuzac : le contentieux du compte en Suisse',
+            'description': 'md5:401969c5d318c061f86bda1fa359292b',
+            'upload_date': '20160907',
         },
     }
 
@@ -40,6 +39,7 @@ class FranceInterIE(InfoExtractor):
             upload_date_list = upload_date_str.split()
             upload_date_list.reverse()
             upload_date_list[1] = '%02d' % (month_by_name(upload_date_list[1], lang='fr') or 0)
+            upload_date_list[2] = '%02d' % int(upload_date_list[2])
             upload_date = ''.join(upload_date_list)
         else:
             upload_date = None