[git] GPGME - branch, master, updated. gpgme-1.8.0-105-g57e64d0

by Justus Winter cvs at cvs.gnupg.org
Mon Mar 20 16:55:34 CET 2017


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  57e64d019d993fdeb4323def5352f8ecc98c6fd9 (commit)
      from  16b202d9999591b71fb8bb49f6db10ef96d4cbe8 (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 57e64d019d993fdeb4323def5352f8ecc98c6fd9
Author: Justus Winter <justus at g10code.com>
Date:   Mon Mar 20 16:53:29 2017 +0100

    python: Fix version check.
    
    * lang/python/tests/support.py (assert_gpg_version): Cope with
    non-released versions.
    
    Fixes-commit: e1cf8bab319ba1dea41ba5d711dbb66ffd8e6fd6
    Signed-off-by: Justus Winter <justus at g10code.com>

diff --git a/lang/python/tests/support.py b/lang/python/tests/support.py
index 8f9d645..611986b 100644
--- a/lang/python/tests/support.py
+++ b/lang/python/tests/support.py
@@ -22,13 +22,15 @@ import contextlib
 import shutil
 import sys
 import os
+import re
 import tempfile
 import time
 import gpg
 
 def assert_gpg_version(version=(2, 1, 0)):
     with gpg.Context() as c:
-        if tuple(map(int, c.engine_info.version.split('.'))) < version:
+        clean_version = re.match(r'\d+\.\d+\.\d+', c.engine_info.version).group(0)
+        if tuple(map(int, clean_version.split('.'))) < version:
             print("GnuPG too old: have {0}, need {1}.".format(
                 c.engine_info.version, '.'.join(version)))
             sys.exit(77)

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

Summary of changes:
 lang/python/tests/support.py | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)


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




More information about the Gnupg-commits mailing list