Multithreading with GPGME Python Bindings

Werner Koch wk at gnupg.org
Tue Jan 17 10:54:28 CET 2023


On Mon, 16 Jan 2023 07:55, Jan Girlich said:
> Is the call to "gpgme_check_version" maybe done implicitly by the
> Python bindings?

Yes.  See gpgme/lang/python/src/core.py

  # check_version also makes sure that several subsystems are properly
  # initialized, and it must be run at least once before invoking any
  # other function.  We do it here so that the user does not have to do
  # it unless she really wants to check for a certain version.
  check_version()

> Do I have to call "gpgme-config --version" before to safely do

No, this is a helper to compile against gpgme - it returns suggested
compiler and linker flags.

Make sure that one context object is only used by one thread at a time.


Salam-Shalom,

   Werner

-- 
The pioneers of a warless world are the youth that
refuse military service.             - A. Einstein
-------------- next part --------------
A non-text attachment was scrubbed...
Name: openpgp-digital-signature.asc
Type: application/pgp-signature
Size: 227 bytes
Desc: not available
URL: <https://lists.gnupg.org/pipermail/gnupg-users/attachments/20230117/60404bb9/attachment.sig>


More information about the Gnupg-users mailing list