From 4b1144ff063647b8d1f572633dc72e8d9d5b6f0a Mon Sep 17 00:00:00 2001 From: Cameron Rossington Date: Wed, 28 Aug 2019 01:27:39 -0400 Subject: [PATCH] Look for podcast description in generic extractor. Tries sequentially to find common tags containing episode descriptions for podcasts when using the generic extractor. Silently allows description to be None if there are not any found. --- youtube_dl/extractor/generic.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/youtube_dl/extractor/generic.py b/youtube_dl/extractor/generic.py index d34fc4b15..65ff452ac 100644 --- a/youtube_dl/extractor/generic.py +++ b/youtube_dl/extractor/generic.py @@ -2164,10 +2164,19 @@ class GenericIE(InfoExtractor): if not next_url: continue + description = None + for tag in ('description', 'content:encoded', 'itunes:summary', 'itunes:subtitle'): + try: + description = it.find(tag).text + break + except AttributeError: + pass + entries.append({ '_type': 'url_transparent', 'url': next_url, 'title': it.find('title').text, + 'description': description }) return {