From d84347f367630ca8d1683a9fe8307a0fc0dbbd27 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 ce8252f6a..80b691ac7 100644 --- a/youtube_dl/extractor/generic.py +++ b/youtube_dl/extractor/generic.py @@ -2185,10 +2185,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 {