From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 29D521389E2 for ; Thu, 25 Dec 2014 20:43:17 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id C6FC8E0968; Thu, 25 Dec 2014 20:43:14 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id C332DE0969 for ; Thu, 25 Dec 2014 20:43:13 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 1505A340589 for ; Thu, 25 Dec 2014 20:43:13 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 36F05D5D8 for ; Thu, 25 Dec 2014 20:43:10 +0000 (UTC) From: "Brian Dolbec" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Brian Dolbec" Message-ID: <1419539495.5cbb4cb9100dc4451d359e7a711d2bd84837c64c.dol-sen@gentoo> Subject: [gentoo-commits] proj/gentoo-keys:master commit in: gkeys/gkeys/ X-VCS-Repository: proj/gentoo-keys X-VCS-Files: gkeys/gkeys/SaneConfigParser.py X-VCS-Directories: gkeys/gkeys/ X-VCS-Committer: dol-sen X-VCS-Committer-Name: Brian Dolbec X-VCS-Revision: 5cbb4cb9100dc4451d359e7a711d2bd84837c64c X-VCS-Branch: master Date: Thu, 25 Dec 2014 20:43:10 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 16b9c945-21f7-4227-9b6c-ba73273cc1ed X-Archives-Hash: 01a322c0ab41c6d0801ccb220ba37586 commit: 5cbb4cb9100dc4451d359e7a711d2bd84837c64c Author: Brian Dolbec gentoo org> AuthorDate: Thu Dec 25 20:31:35 2014 +0000 Commit: Brian Dolbec gmail com> CommitDate: Thu Dec 25 20:31:35 2014 +0000 URL: http://sources.gentoo.org/gitweb/?p=proj/gentoo-keys.git;a=commit;h=5cbb4cb9 gkeys/SaneConfigParser: Fix py3 imports --- gkeys/gkeys/SaneConfigParser.py | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/gkeys/gkeys/SaneConfigParser.py b/gkeys/gkeys/SaneConfigParser.py index 3bb69b5..0616335 100644 --- a/gkeys/gkeys/SaneConfigParser.py +++ b/gkeys/gkeys/SaneConfigParser.py @@ -1,14 +1,11 @@ import sys -# py3.2 -if sys.hexversion >= 0x30200f0: - from configparser import configparser as ConfigParser +try: + from configparser import ConfigParser from configparser import NoSectionError - py3 = True -else: +except: from ConfigParser import ConfigParser, NoSectionError - py3 = False class SaneConfigParser(ConfigParser):