lists.arthurdejong.org
RSS feed

python-stdnum branch master updated. 0.9-6-g2405c89

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

python-stdnum branch master updated. 0.9-6-g2405c89



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  2405c89652607261587cfd619c723c805c2cf852 (commit)
      from  a4012f59d8afa3dcb3030809cb77705cb964cf28 (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 -----------------------------------------------------------------
http://arthurdejong.org/git/python-stdnum/commit/?id=2405c89652607261587cfd619c723c805c2cf852

commit 2405c89652607261587cfd619c723c805c2cf852
Author: Jussi Räsänen <jussi@skyred.fi>
Date:   Wed Mar 5 18:57:34 2014 +0200

    Added a simple backwards compability check

diff --git a/stdnum/eu/vat.py b/stdnum/eu/vat.py
index 460bb38..573852c 100644
--- a/stdnum/eu/vat.py
+++ b/stdnum/eu/vat.py
@@ -125,6 +125,9 @@ def check_vies(number):  # pragma: no cover (no tests for 
this function)
     global _vies_client
     if not _vies_client:
         from suds.client import Client
-        from urllib import getproxies
+        try:
+            from urllib import getproxies
+        except ImportError:
+            from urllib.request import getproxies
         _vies_client = Client(vies_wsdl, proxy=getproxies())
     return _vies_client.service.checkVat(number[:2], number[2:])

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

Summary of changes:
 stdnum/eu/vat.py |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)


hooks/post-receive
-- 
python-stdnum
-- 
To unsubscribe send an email to
python-stdnum-commits-unsubscribe@lists.arthurdejong.org or see
http://lists.arthurdejong.org/python-stdnum-commits/