From 9cffc9f1869249a70c527a784c64ddc902ee8d48 Mon Sep 17 00:00:00 2001 From: Mark Huang Date: Mon, 8 Jan 2007 18:11:54 +0000 Subject: [PATCH] print GPG errors to log --- PLC/GPG.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/PLC/GPG.py b/PLC/GPG.py index 0101e47..4182f60 100644 --- a/PLC/GPG.py +++ b/PLC/GPG.py @@ -7,7 +7,7 @@ # Mark Huang # Copyright (C) 2006 The Trustees of Princeton University # -# $Id: GPG.py,v 1.1 2006/12/15 18:21:57 mlhuang Exp $ +# $Id: GPG.py,v 1.2 2007/01/05 18:50:40 mlhuang Exp $ # import xmlrpclib @@ -56,13 +56,14 @@ def gpg_sign(methodname, args, secret_keyring, keyring): p.stdin.write(message) p.stdin.close() signature = p.stdout.read() + err = p.stderr.read() rc = p.wait() # Clean up shutil.rmtree(homedir) if rc: - raise PLCAuthenticationFailure, "GPG signing failed with return code %d" % rc + raise PLCAuthenticationFailure, "GPG signing failed with return code %d: %s" % (rc, err) return signature -- 2.43.0