From 35b588f57e8d425d3614a00c351cddeb397ad7e3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rodolfo=20Garc=C3=ADa=20Pe=C3=B1as=20=28kix=29?= Date: Thu, 3 Sep 2020 21:06:06 +0200 Subject: [PATCH] six: changed offlineimap/repository/__init__.py MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This patch removes the library six, compatible with python2. I need change these re-raise calls. Signed-off-by: Rodolfo García Peñas (kix) --- offlineimap/repository/__init__.py | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/offlineimap/repository/__init__.py b/offlineimap/repository/__init__.py index 6a202eb..a177f26 100644 --- a/offlineimap/repository/__init__.py +++ b/offlineimap/repository/__init__.py @@ -15,7 +15,6 @@ # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA from sys import exc_info -import six try: from configparser import NoSectionError @@ -68,18 +67,16 @@ class Repository: except NoSectionError: errstr = ("Could not find section '%s' in configuration. Required " "for account '%s'." % ('Repository %s' % name, account)) - six.reraise(OfflineImapError, - OfflineImapError(errstr, OfflineImapError.ERROR.REPO), - exc_info()[2]) + raise OfflineImapError(errstr, OfflineImapError.ERROR.REPO, + exc_info()[2]) try: repo = typemap[repostype] except KeyError: errstr = "'%s' repository not supported for '%s' repositories." % \ (repostype, reqtype) - six.reraise(OfflineImapError, - OfflineImapError(errstr, OfflineImapError.ERROR.REPO), - exc_info()[2]) + raise OfflineImapError(errstr, OfflineImapError.ERROR.REPO, + exc_info()[2]) return repo(name, account)