From: W. Trevor King Date: Thu, 18 Oct 2012 17:38:19 +0000 (-0400) Subject: rss2email: fix e.__cause__ -> self.__cause__ typos in exception logging. X-Git-Tag: v3.0~72^2~4 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=4e598baa003a6cc013924f38959e630bbc264545;p=rss2email.git rss2email: fix e.__cause__ -> self.__cause__ typos in exception logging. --- diff --git a/rss2email.py b/rss2email.py index 4fa7edb..fc87a83 100755 --- a/rss2email.py +++ b/rss2email.py @@ -81,7 +81,7 @@ class RSS2EmailError (Exception): def log(self): LOG.error(str(self)) if self.__cause__ is not None: - LOG.error('cause: {}'.format(e.__cause__)) + LOG.error('cause: {}'.format(self.__cause__)) class TimeoutError (RSS2EmailError): @@ -118,8 +118,8 @@ class SMTPConnectionError (ValueError, RSS2EmailError): LOG.warning( 'check your config file to confirm that smtp-server and other ' 'mail server settings are configured properly') - if hasattr(e.__cause__, 'reason'): - LOG.error('reason: {}'.format(e.__cause__.reason)) + if hasattr(self.__cause__, 'reason'): + LOG.error('reason: {}'.format(self.__cause__.reason)) class SMTPAuthenticationError (SMTPConnectionError):