소스 검색

[soundcloud] Raise an error instead of calling 'report_error'

Jaime Marquínez Ferrándiz 10 년 전
부모
커밋
214e74bf6f
1개의 변경된 파일2개의 추가작업 그리고 3개의 파일을 삭제
  1. 2 3
      youtube_dl/extractor/soundcloud.py

+ 2 - 3
youtube_dl/extractor/soundcloud.py

@@ -279,9 +279,8 @@ class SoundcloudSetIE(SoundcloudIE):
         info = self._download_json(resolv_url, full_title)
 
         if 'errors' in info:
-            for err in info['errors']:
-                self._downloader.report_error('unable to download video webpage: %s' % compat_str(err['error_message']))
-            return
+            msgs = (compat_str(err['error_message']) for err in info['errors'])
+            raise ExtractorError('unable to download video webpage: %s' % ','.join(msgs))
 
         return {
             '_type': 'playlist',