[git] GPGME - branch, master, updated. gpgme-1.6.0-360-g594c3b8

by Justus Winter cvs at cvs.gnupg.org
Wed Sep 14 14:39:31 CEST 2016


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GnuPG Made Easy".

The branch, master has been updated
       via  594c3b8b052e60b6be77ed532fe46549133a9726 (commit)
       via  4011b2b2a1050f0837e989da3db9b5459e71ccd6 (commit)
       via  44d18200d5ffe8691e18d93ce6c534660702b982 (commit)
       via  f6cd560ca74248dd719a37cfb34386148727a92d (commit)
      from  99db351288d5bb075f124ef10e540e25bc36b70a (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 594c3b8b052e60b6be77ed532fe46549133a9726
Author: Justus Winter <justus at g10code.com>
Date:   Wed Sep 14 14:36:29 2016 +0200

    python: Clarify that we support Python 2.7 too.
    
    * lang/python/README: Use 'Python' instead of 'Python 3'.
    * lang/python/pyme/version.py.in: Likewise.
    * lang/python/setup.py.in: Add classifier for 2.7, drop 3 only.
    
    Signed-off-by: Justus Winter <justus at g10code.com>

diff --git a/lang/python/README b/lang/python/README
index 7ce8894..08e9863 100644
--- a/lang/python/README
+++ b/lang/python/README
@@ -6,7 +6,7 @@ https://www.gnupg.org/related_software/gpgme/
 
 PyMe uses SWIG to create wrapper functions with automatic type
 conversions.  This way most of the functions and types are converted
-from C into Python 3 automatically by SWIG, reducing the maintenance
+from C into Python automatically by SWIG, reducing the maintenance
 cost of the binginds.
 
 * Authors
diff --git a/lang/python/pyme/version.py.in b/lang/python/pyme/version.py.in
index 5fd9ce2..cfb9510 100644
--- a/lang/python/pyme/version.py.in
+++ b/lang/python/pyme/version.py.in
@@ -41,7 +41,7 @@ Copyright (C) 2002 John Goerzen"""
 author = "The GnuPG hackers"
 author_email = "gnupg-devel at gnupg.org"
 
-description = "Python 3 support for GPGME GnuPG cryptography library"
+description = "Python support for GPGME GnuPG cryptography library"
 homepage = "https://gnupg.org"
 
 license = """Copyright (C) 2016 g10 Code GmbH
diff --git a/lang/python/setup.py.in b/lang/python/setup.py.in
index a9c7691..933e780 100755
--- a/lang/python/setup.py.in
+++ b/lang/python/setup.py.in
@@ -175,8 +175,8 @@ setup(name="pyme3",
           'Development Status :: 4 - Beta',
           'Intended Audience :: Developers',
           'License :: OSI Approved :: GNU Lesser General Public License v2 or later (LGPLv2+)',
+          'Programming Language :: Python :: 2.7',
           'Programming Language :: Python :: 3',
-          'Programming Language :: Python :: 3 :: Only',
           'Programming Language :: Python :: 3.4',
           'Programming Language :: Python :: 3.5',
           'Programming Language :: Python :: 3.6',

commit 4011b2b2a1050f0837e989da3db9b5459e71ccd6
Author: Justus Winter <justus at g10code.com>
Date:   Wed Sep 14 14:35:00 2016 +0200

    python: Trim imports.
    
    * lang/python/examples/encrypt-to-all.py: Drop unused import of 'os'.
    * lang/python/examples/signverify.py: Likewise.
    * lang/python/examples/simple.py: Likewise.
    * lang/python/examples/verifydetails.py: Likewise.
    
    Signed-off-by: Justus Winter <justus at g10code.com>

diff --git a/lang/python/examples/encrypt-to-all.py b/lang/python/examples/encrypt-to-all.py
index bb8225b..35873bd 100755
--- a/lang/python/examples/encrypt-to-all.py
+++ b/lang/python/examples/encrypt-to-all.py
@@ -26,7 +26,6 @@ from __future__ import absolute_import, print_function, unicode_literals
 del absolute_import, print_function, unicode_literals
 
 import sys
-import os
 import pyme
 
 with pyme.Context(armor=True) as c:
diff --git a/lang/python/examples/signverify.py b/lang/python/examples/signverify.py
index f12e065..03bc0a6 100755
--- a/lang/python/examples/signverify.py
+++ b/lang/python/examples/signverify.py
@@ -23,7 +23,6 @@ from __future__ import absolute_import, print_function, unicode_literals
 del absolute_import, print_function, unicode_literals
 
 import sys
-import os
 import pyme
 from pyme.constants.sig import mode
 
diff --git a/lang/python/examples/simple.py b/lang/python/examples/simple.py
index ccd7cb4..5598487 100755
--- a/lang/python/examples/simple.py
+++ b/lang/python/examples/simple.py
@@ -21,7 +21,6 @@ from __future__ import absolute_import, print_function, unicode_literals
 del absolute_import, print_function, unicode_literals
 
 import sys
-import os
 import pyme
 
 with pyme.Context(armor=True) as c:
diff --git a/lang/python/examples/verifydetails.py b/lang/python/examples/verifydetails.py
index 63f40c1..fa34926 100755
--- a/lang/python/examples/verifydetails.py
+++ b/lang/python/examples/verifydetails.py
@@ -21,7 +21,6 @@ from __future__ import absolute_import, print_function, unicode_literals
 del absolute_import, print_function, unicode_literals
 
 import sys
-import os
 from pyme import core
 from pyme.constants import protocol
 

commit 44d18200d5ffe8691e18d93ce6c534660702b982
Author: Justus Winter <justus at g10code.com>
Date:   Wed Sep 14 14:34:14 2016 +0200

    python: Improve error handling.
    
    * lang/python/gpgme.i (gpgme_engine_info_t): Improve error handling.
    
    Signed-off-by: Justus Winter <justus at g10code.com>

diff --git a/lang/python/gpgme.i b/lang/python/gpgme.i
index bc957e5..458ae7f 100644
--- a/lang/python/gpgme.i
+++ b/lang/python/gpgme.i
@@ -452,14 +452,24 @@
     size++;
   }
   $result = PyList_New(size);
+  if ($result == NULL)
+    return NULL;	/* raise */
   for (i=0,curr=$1; i<size; i++,curr=curr->next) {
     PyObject *fragile, *o;
     fragile = SWIG_NewPointerObj(SWIG_as_voidptr(curr), $1_descriptor,
                                  %newpointer_flags);
+    if (fragile == NULL)
+      {
+        Py_DECREF($result);
+        return NULL;	/* raise */
+      }
     o = _pyme_wrap_result(fragile, "EngineInfo");
-    if (o == NULL)
-      return NULL;	/* raise */
     Py_DECREF(fragile);
+    if (o == NULL)
+      {
+        Py_DECREF($result);
+        return NULL;	/* raise */
+      }
     PyList_SetItem($result, i, o);
   }
 }

commit f6cd560ca74248dd719a37cfb34386148727a92d
Author: Justus Winter <justus at g10code.com>
Date:   Wed Sep 14 14:32:48 2016 +0200

    python: Adapt to TOFU changes.
    
    * lang/python/pyme/results.py (TofuInfo): Drop.
    (Signature): The TOFU information moved to the key.
    
    Signed-off-by: Justus Winter <justus at g10code.com>

diff --git a/lang/python/pyme/results.py b/lang/python/pyme/results.py
index bfc26cc..3383896 100644
--- a/lang/python/pyme/results.py
+++ b/lang/python/pyme/results.py
@@ -92,12 +92,9 @@ class SignResult(Result):
 class Notation(Result):
     pass
 
-class TofuInfo(Result):
-    pass
-
 class Signature(Result):
     _type = dict(wrong_key_usage=bool, chain_model=bool)
-    _map = dict(notations=Notation, tofu=TofuInfo)
+    _map = dict(notations=Notation)
 
 class VerifyResult(Result):
     _map = dict(signatures=Signature)

-----------------------------------------------------------------------

Summary of changes:
 lang/python/README                     |  2 +-
 lang/python/examples/encrypt-to-all.py |  1 -
 lang/python/examples/signverify.py     |  1 -
 lang/python/examples/simple.py         |  1 -
 lang/python/examples/verifydetails.py  |  1 -
 lang/python/gpgme.i                    | 14 ++++++++++++--
 lang/python/pyme/results.py            |  5 +----
 lang/python/pyme/version.py.in         |  2 +-
 lang/python/setup.py.in                |  2 +-
 9 files changed, 16 insertions(+), 13 deletions(-)


hooks/post-receive
-- 
GnuPG Made Easy
http://git.gnupg.org




More information about the Gnupg-commits mailing list