public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] gentoo-x86 commit in app-crypt/monkeysign/files: monkeysign-2.0.2-smtplib.patch monkeysign-1.2-test-no-emit-version.patch monkeysign-1.1-rst2s5.patch
@ 2015-02-02 22:25 Kristian Fiskerstrand (k_f)
  0 siblings, 0 replies; only message in thread
From: Kristian Fiskerstrand (k_f) @ 2015-02-02 22:25 UTC (permalink / raw
  To: gentoo-commits

k_f         15/02/02 22:25:45

  Added:                monkeysign-2.0.2-smtplib.patch
  Removed:              monkeysign-1.2-test-no-emit-version.patch
                        monkeysign-1.1-rst2s5.patch
  Log:
  Fix NameError: Global name 'SMTPException' is not defined. The patch is already submitted and included upstream.
  
  (Portage version: 2.2.14/cvs/Linux x86_64, signed Manifest commit with key 0xFED5002857C1ABFA!)

Revision  Changes    Path
1.1                  app-crypt/monkeysign/files/monkeysign-2.0.2-smtplib.patch

file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-crypt/monkeysign/files/monkeysign-2.0.2-smtplib.patch?rev=1.1&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-crypt/monkeysign/files/monkeysign-2.0.2-smtplib.patch?rev=1.1&content-type=text/plain

Index: monkeysign-2.0.2-smtplib.patch
===================================================================
From 9e6699ec432b23d56a0728bb25fc2ed1a47a85e6 Mon Sep 17 00:00:00 2001
From: Kristian Fiskerstrand <kf@sumptuouscapital.com>
Date: Mon, 2 Feb 2015 20:38:07 +0100
Subject: [PATCH] ui.py: Make sure to use smtplib namespace

Make sure to properly use the smtplib namespace for SMTPException
in order to avoid a NameError for undefined exception in global
scope.
---
 monkeysign/ui.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/monkeysign/ui.py b/monkeysign/ui.py
index c9b6a30..c2308c8 100644
--- a/monkeysign/ui.py
+++ b/monkeysign/ui.py
@@ -359,7 +359,7 @@ expects an EmailFactory email, but will not mail if nomail is set"""
                     self.abort(_('Unexpected SMTP server error while talking to %s, code: %s (%s)') % (self.options.smtpserver, code, srvmsg))
                 try:
                     server.starttls()
-                except SMTPException:
+                except smtplib.SMTPException:
                     self.warn(_('SMTP server does not support STARTTLS'))
                     if self.options.smtpuser: self.warn(_('authentication credentials will be sent in clear text'))
                 if self.options.smtpuser:
-- 
2.2.2






^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2015-02-02 22:25 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-02-02 22:25 [gentoo-commits] gentoo-x86 commit in app-crypt/monkeysign/files: monkeysign-2.0.2-smtplib.patch monkeysign-1.2-test-no-emit-version.patch monkeysign-1.1-rst2s5.patch Kristian Fiskerstrand (k_f)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox