From da4de959dfb4cef9b79e6b65ed7dbf6f95092904 Mon Sep 17 00:00:00 2001 From: Philipp Hagemeister Date: Sun, 27 Jan 2013 04:05:53 +0100 Subject: [PATCH] 8tracks: Better default titles --- test/tests.json | 20 +++++++++++--------- youtube_dl/InfoExtractors.py | 5 +++-- 2 files changed, 14 insertions(+), 11 deletions(-) diff --git a/test/tests.json b/test/tests.json index 2fdd7f0f5..a06266689 100644 --- a/test/tests.json +++ b/test/tests.json @@ -244,57 +244,59 @@ "file": "11885610.m4a", "md5": "96ce57f24389fc8734ce47f4c1abcc55", "info_dict": { - "title": "youtube-dl test track 1 \"'/\\\u00e4\u21ad", - "uploader": "youtue-dl project<>\"'" + "title": "youtue-dl project<>\"' - youtube-dl test track 1 \"'/\\\u00e4\u21ad", + "uploader_id": "ytdl" } }, { "file": "11885608.m4a", "md5": "4ab26f05c1f7291ea460a3920be8021f", "info_dict": { - "title": "youtube-dl test track 2 \"'/\\\u00e4\u21ad" + "title": "youtube-dl project - youtube-dl test track 2 \"'/\\\u00e4\u21ad", + "uploader_id": "ytdl" + } }, { "file": "11885679.m4a", "md5": "d30b5b5f74217410f4689605c35d1fd7", "info_dict": { - "title": "youtube-dl test track 3 \"'/\\\u00e4\u21ad" + "title": "youtube-dl project as well - youtube-dl test track 3 \"'/\\\u00e4\u21ad" } }, { "file": "11885680.m4a", "md5": "4eb0a669317cd725f6bbd336a29f923a", "info_dict": { - "title": "youtube-dl test track 4 \"'/\\\u00e4\u21ad" + "title": "youtube-dl project as well - youtube-dl test track 4 \"'/\\\u00e4\u21ad" } }, { "file": "11885682.m4a", "md5": "1893e872e263a2705558d1d319ad19e8", "info_dict": { - "title": "youtube-dl test track 5 \"'/\\\u00e4\u21ad" + "title": "PH - youtube-dl test track 5 \"'/\\\u00e4\u21ad" } }, { "file": "11885683.m4a", "md5": "b673c46f47a216ab1741ae8836af5899", "info_dict": { - "title": "youtube-dl test track 6 \"'/\\\u00e4\u21ad" + "title": "PH - youtube-dl test track 6 \"'/\\\u00e4\u21ad" } }, { "file": "11885684.m4a", "md5": "1d74534e95df54986da7f5abf7d842b7", "info_dict": { - "title": "youtube-dl test track 7 \"'/\\\u00e4\u21ad" + "title": "phihag - youtube-dl test track 7 \"'/\\\u00e4\u21ad" } }, { "file": "11885685.m4a", "md5": "f081f47af8f6ae782ed131d38b9cd1c0", "info_dict": { - "title": "youtube-dl test track 8 \"'/\\\u00e4\u21ad" + "title": "phihag - youtube-dl test track 8 \"'/\\\u00e4\u21ad" } } ] diff --git a/youtube_dl/InfoExtractors.py b/youtube_dl/InfoExtractors.py index 0af59bce2..ff085b0ee 100755 --- a/youtube_dl/InfoExtractors.py +++ b/youtube_dl/InfoExtractors.py @@ -3892,8 +3892,9 @@ class EightTracksIE(InfoExtractor): info = { 'id': track_data['id'], 'url': track_data['track_file_stream_url'], - 'title': track_data['name'], - 'uploader': track_data['performer'], + 'title': track_data['performer'] + u' - ' + track_data['name'], + 'raw_title': track_data['name'], + 'uploader_id': data['user']['login'], 'ext': 'm4a', } res.append(info)