changeset 437ada79aa29 in modules/country:default
details: https://hg.tryton.org/modules/country?cmd=changeset&node=437ada79aa29
description:
        Use Tryton's CDN to download postal codes

        issue8952
        review360561002
diffstat:

 CHANGELOG                      |  1 +
 scripts/import_postal_codes.py |  2 +-
 2 files changed, 2 insertions(+), 1 deletions(-)

diffs (20 lines):

diff -r b80f8e665d09 -r 437ada79aa29 CHANGELOG
--- a/CHANGELOG Thu Jan 20 23:05:44 2022 +0100
+++ b/CHANGELOG Thu Jan 20 23:36:34 2022 +0100
@@ -1,3 +1,4 @@
+* Use Tryton's CDN to download postal codes
 * Support pycountry 22.1.10
 * Manage unknown subdivision type
 * Add support for Python 3.10
diff -r b80f8e665d09 -r 437ada79aa29 scripts/import_postal_codes.py
--- a/scripts/import_postal_codes.py    Thu Jan 20 23:05:44 2022 +0100
+++ b/scripts/import_postal_codes.py    Thu Jan 20 23:36:34 2022 +0100
@@ -39,7 +39,7 @@
 
 def fetch(code):
     sys.stderr.write('Fetching')
-    url = 'https://download.geonames.org/export/zip/%s.zip' % code
+    url = 'https://downloads-cdn.tryton.org/geonames/%s.zip' % code
     try:
         responce = urlopen(url)
     except HTTPError as e:

Reply via email to