From 8ce8768465f8cf5c3cb99e19d0cbe32f6863963c Mon Sep 17 00:00:00 2001 From: Marian Steinbach Date: Mon, 8 Oct 2018 08:42:29 +0200 Subject: [PATCH] Improve error messages in export --- export/__init__.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/export/__init__.py b/export/__init__.py index 64af277..79d00b2 100644 --- a/export/__init__.py +++ b/export/__init__.py @@ -122,7 +122,7 @@ def download_icon(icon_url): try: file_name = os.path.basename(icon_url)[-1] except IndexError as exc: - logging.error("Error in URL %s: %s", icon_url, exc) + logging.error("Could not get file name from URL %s. Not downloading. Details: %s", icon_url, exc) return None if file_name != "" and "." in file_name: @@ -139,7 +139,7 @@ def download_icon(icon_url): try: extension = default_endings[ctype] except KeyError: - logging.error("No file ending defined for icon type '%s'", ctype) + logging.error("No file ending defined for icon type %s. Not downloading.", ctype) return None filename = content_hash + "." + extension.lower()