From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (unknown [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 8A5DB1381FA for ; Tue, 27 May 2014 20:56:52 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id C87E5E08C0; Tue, 27 May 2014 20:56:46 +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 6DB4EE086A for ; Tue, 27 May 2014 20:56:45 +0000 (UTC) Received: from spoonbill.gentoo.org (unknown [81.93.255.5]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 8A2AD33F922 for ; Tue, 27 May 2014 20:56:44 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by spoonbill.gentoo.org (Postfix) with ESMTP id E8A5D182E3 for ; Tue, 27 May 2014 20:56:40 +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: <1400953128.4141af80341062e6b6db0b636a05988fa09e1f9f.dol-sen@gentoo> Subject: [gentoo-commits] proj/gentoo-keys:master commit in: gkeys/ X-VCS-Repository: proj/gentoo-keys X-VCS-Files: gkeys/config.py X-VCS-Directories: gkeys/ X-VCS-Committer: dol-sen X-VCS-Committer-Name: Brian Dolbec X-VCS-Revision: 4141af80341062e6b6db0b636a05988fa09e1f9f X-VCS-Branch: master Date: Tue, 27 May 2014 20:56:40 +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: f82fd3a5-2b6f-4f61-8d99-272e7b5bb08e X-Archives-Hash: 14fe5bc1aa34c3b3ee1a1ef72b5a347c commit: 4141af80341062e6b6db0b636a05988fa09e1f9f Author: Pavlos Ratis gentoo org> AuthorDate: Sat May 24 17:26:19 2014 +0000 Commit: Brian Dolbec gmail com> CommitDate: Sat May 24 17:38:48 2014 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/gentoo-keys.git;a=commit;h=4141af80 subclass __new__ to make both gkeys and gkeyldap work properly --- gkeys/config.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/gkeys/config.py b/gkeys/config.py index b20d5cd..9d629b7 100644 --- a/gkeys/config.py +++ b/gkeys/config.py @@ -130,6 +130,13 @@ class GKEY(namedtuple('GKEY', ['nick', 'name', 'keyid', 'longkeyid', 'keydir', 'fingerprint'])): '''Class to hold the relavent info about a key''' + # subclass __new__ to make both gkeys and gkeyldap work properly + # delete it when keyid and longkeyid are removed from LDAP + def __new__(cls, nick=None, name=None, keydir=None, fingerprint=None, + keyid=None, longkeyid=None): + return super(GKEY, cls).__new__(cls, nick, name, keydir, fingerprint, + keyid, longkeyid) + field_types = {'nick': str, 'name': str, 'keyid': list, 'longkeyid': list, 'keydir': str, 'fingerprint': list} field_separator = "|"