From 353479294b9eb7e2163dabb659aa1ad1010f7afa Mon Sep 17 00:00:00 2001 From: Antonio Ospite Date: Thu, 9 Jul 2015 17:15:28 +0200 Subject: [PATCH] winfreed.py: print also errors with no reason or code attribute --- winfreed.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/winfreed.py b/winfreed.py index d25a75f..b58358c 100755 --- a/winfreed.py +++ b/winfreed.py @@ -76,6 +76,8 @@ def download_file(src_url, dest_dir): print 'Reason: ', e.reason elif hasattr(e, 'code'): print 'Error code: ', e.code + else: + print e return # get the final URL after possible redirect have been followed -- 2.1.4