lists.arthurdejong.org
RSS feed

python-stdnum branch master updated. 1.20-14-g0ceb2b9

[Date Prev][Date Next] [Thread Prev][Thread Next]

python-stdnum branch master updated. 1.20-14-g0ceb2b9



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 "python-stdnum".

The branch, master has been updated
       via  0ceb2b9ad23bd3fb29afcafe760a1101b73e639d (commit)
      from  6c2873c86bde0c8d87d867a8ade473d6a53657ea (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 -----------------------------------------------------------------
https://arthurdejong.org/git/python-stdnum/commit/?id=0ceb2b9ad23bd3fb29afcafe760a1101b73e639d

commit 0ceb2b9ad23bd3fb29afcafe760a1101b73e639d
Author: Arthur de Jong <arthur@arthurdejong.org>
Date:   Sun Sep 15 14:57:06 2024 +0200

    Ensure get_soap_client() caches with verify
    
    This fixes the get_soap_client() function to cache SOAP clients taking
    the verify argument into account.
    
    Fixes 3fcebb2

diff --git a/stdnum/util.py b/stdnum/util.py
index b625c72..eeb89ed 100644
--- a/stdnum/util.py
+++ b/stdnum/util.py
@@ -312,7 +312,7 @@ def get_soap_client(wsdlurl, timeout=30, verify=True):  # 
pragma: no cover (not
     # this function isn't automatically tested because the functions using
     # it are not automatically tested and it requires network access for proper
     # testing
-    if (wsdlurl, timeout) not in _soap_clients:
+    if (wsdlurl, timeout, verify) not in _soap_clients:
         for function in (_get_zeep_soap_client, _get_suds_soap_client, 
_get_pysimplesoap_soap_client):
             try:
                 client = function(wsdlurl, timeout, verify)
@@ -321,5 +321,5 @@ def get_soap_client(wsdlurl, timeout=30, verify=True):  # 
pragma: no cover (not
                 pass
         else:
             raise ImportError('No SOAP library (such as zeep) found')
-        _soap_clients[(wsdlurl, timeout)] = client
-    return _soap_clients[(wsdlurl, timeout)]
+        _soap_clients[(wsdlurl, timeout, verify)] = client
+    return _soap_clients[(wsdlurl, timeout, verify)]

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

Summary of changes:
 stdnum/util.py | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)


hooks/post-receive
-- 
python-stdnum