From e5d64d685389d15caf1c247cfa2b124a6e5e786b Mon Sep 17 00:00:00 2001 From: Benedikt Willi Date: Mon, 15 Aug 2022 16:21:34 +0200 Subject: [PATCH] Update inlinepatterns.py --- mdx_oembed/inlinepatterns.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/mdx_oembed/inlinepatterns.py b/mdx_oembed/inlinepatterns.py index 02054a2..b427151 100644 --- a/mdx_oembed/inlinepatterns.py +++ b/mdx_oembed/inlinepatterns.py @@ -19,6 +19,7 @@ class OEmbedLinkPattern(Pattern): def handleMatch(self, match): html = self.get_oembed_html_for_match(match) + LOG.info(html) if html is None: return None else: @@ -28,11 +29,14 @@ class OEmbedLinkPattern(Pattern): def get_oembed_html_for_match(self, match): url = match.group(3).strip() + LOG.info(url) try: response = self.consumer.embed(url) except oembed.OEmbedNoEndpoint: + LOG.error("No OEmbed Endpoint") return None except Exception as e: + LOG.error(e) return None else: return response['html']