[crux-commits] ports/contrib (3.6): python3-babel: 2.8.0 -> 2.9.1

crux at crux.nu crux at crux.nu
Wed Apr 28 22:19:20 UTC 2021


commit 89209e29413017f33e2fac27fc2f1286a7015eea
Author: Tim Biermann <tbier at posteo.de>
Date:   Wed Apr 28 22:09:13 2021 +0000

    python3-babel: 2.8.0 -> 2.9.1

diff --git a/python3-babel/.footprint b/python3-babel/.footprint
index f1a7b8657..8fe9309ff 100644
--- a/python3-babel/.footprint
+++ b/python3-babel/.footprint
@@ -4,14 +4,14 @@ drwxr-xr-x	root/root	usr/bin/
 drwxr-xr-x	root/root	usr/lib/
 drwxr-xr-x	root/root	usr/lib/python3.9/
 drwxr-xr-x	root/root	usr/lib/python3.9/site-packages/
-drwxr-xr-x	root/root	usr/lib/python3.9/site-packages/Babel-2.8.0-py3.9.egg-info/
--rw-r--r--	root/root	usr/lib/python3.9/site-packages/Babel-2.8.0-py3.9.egg-info/PKG-INFO
--rw-r--r--	root/root	usr/lib/python3.9/site-packages/Babel-2.8.0-py3.9.egg-info/SOURCES.txt
--rw-r--r--	root/root	usr/lib/python3.9/site-packages/Babel-2.8.0-py3.9.egg-info/dependency_links.txt
--rw-r--r--	root/root	usr/lib/python3.9/site-packages/Babel-2.8.0-py3.9.egg-info/entry_points.txt
--rw-r--r--	root/root	usr/lib/python3.9/site-packages/Babel-2.8.0-py3.9.egg-info/not-zip-safe
--rw-r--r--	root/root	usr/lib/python3.9/site-packages/Babel-2.8.0-py3.9.egg-info/requires.txt
--rw-r--r--	root/root	usr/lib/python3.9/site-packages/Babel-2.8.0-py3.9.egg-info/top_level.txt
+drwxr-xr-x	root/root	usr/lib/python3.9/site-packages/Babel-2.9.1-py3.9.egg-info/
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/Babel-2.9.1-py3.9.egg-info/PKG-INFO
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/Babel-2.9.1-py3.9.egg-info/SOURCES.txt
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/Babel-2.9.1-py3.9.egg-info/dependency_links.txt
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/Babel-2.9.1-py3.9.egg-info/entry_points.txt
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/Babel-2.9.1-py3.9.egg-info/not-zip-safe
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/Babel-2.9.1-py3.9.egg-info/requires.txt
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/Babel-2.9.1-py3.9.egg-info/top_level.txt
 drwxr-xr-x	root/root	usr/lib/python3.9/site-packages/babel/
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/__init__.py
 drwxr-xr-x	root/root	usr/lib/python3.9/site-packages/babel/__pycache__/
@@ -327,6 +327,19 @@ drwxr-xr-x	root/root	usr/lib/python3.9/site-packages/babel/locale-data/
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/fa_AF.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/fa_IR.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ff.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ff_Adlm.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ff_Adlm_BF.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ff_Adlm_CM.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ff_Adlm_GH.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ff_Adlm_GM.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ff_Adlm_GN.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ff_Adlm_GW.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ff_Adlm_LR.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ff_Adlm_MR.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ff_Adlm_NE.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ff_Adlm_NG.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ff_Adlm_SL.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ff_Adlm_SN.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ff_Latn.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ff_Latn_BF.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ff_Latn_CM.dat
@@ -489,7 +502,8 @@ drwxr-xr-x	root/root	usr/lib/python3.9/site-packages/babel/locale-data/
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/kok.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/kok_IN.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ks.dat
--rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ks_IN.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ks_Arab.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ks_Arab_IN.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ksb.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ksb_TZ.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ksf.dat
@@ -530,6 +544,8 @@ drwxr-xr-x	root/root	usr/lib/python3.9/site-packages/babel/locale-data/
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/luy_KE.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/lv.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/lv_LV.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/mai.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/mai_IN.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/mas.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/mas_KE.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/mas_TZ.dat
@@ -551,10 +567,14 @@ drwxr-xr-x	root/root	usr/lib/python3.9/site-packages/babel/locale-data/
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ml_IN.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/mn.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/mn_MN.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/mni.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/mni_Beng.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/mni_Beng_IN.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/mr.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/mr_IN.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ms.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ms_BN.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ms_ID.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ms_MY.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/ms_SG.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/mt.dat
@@ -609,6 +629,8 @@ drwxr-xr-x	root/root	usr/lib/python3.9/site-packages/babel/locale-data/
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/pa_Arab_PK.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/pa_Guru.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/pa_Guru_IN.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/pcm.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/pcm_NG.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/pl.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/pl_PL.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/prg.dat
@@ -658,10 +680,16 @@ drwxr-xr-x	root/root	usr/lib/python3.9/site-packages/babel/locale-data/
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/sah_RU.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/saq.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/saq_KE.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/sat.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/sat_Olck.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/sat_Olck_IN.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/sbp.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/sbp_TZ.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/sd.dat
--rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/sd_PK.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/sd_Arab.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/sd_Arab_PK.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/sd_Deva.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/sd_Deva_IN.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/se.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/se_FI.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/se_NO.dat
@@ -707,6 +735,9 @@ drwxr-xr-x	root/root	usr/lib/python3.9/site-packages/babel/locale-data/
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/sr_Latn_ME.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/sr_Latn_RS.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/sr_Latn_XK.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/su.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/su_Latn.dat
+-rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/su_Latn_ID.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/sv.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/sv_AX.dat
 -rw-r--r--	root/root	usr/lib/python3.9/site-packages/babel/locale-data/sv_FI.dat
diff --git a/python3-babel/.signature b/python3-babel/.signature
index 14267f7e0..8b0d36135 100644
--- a/python3-babel/.signature
+++ b/python3-babel/.signature
@@ -1,8 +1,6 @@
 untrusted comment: verify with /etc/ports/contrib.pub
-RWSagIOpLGJF38+xpkrGoSnM1V7IZt/EeaHxCF1doNQhFW3R45FVztiHWA6tIysSHxpFSOa2HesKy3+7SZDuml1XHmOzgLTbdQk=
-SHA256 (Pkgfile) = 77347cfb1f54146861dc4ac64b4661cf65e0766434ea8873bffc02ce1f98db5f
-SHA256 (.footprint) = 862f0d5e1f8afa5a91e17a2774f3be1bac0ea1ce85564ce626c96f8dd2a43534
-SHA256 (python3-babel-2.8.0.tar.gz) = 2d4d29e73e85afd10ff260579303b5479b332eadc393663089dceb14ff6f8b9c
-SHA256 (cldr-common-36.0.zip) = 07279e56c1f4266d140b907ef3ec379dce0a99542303a9628562ac5fe460ba43
-SHA256 (0001-py39.patch) = 4baa6c5b336a357e39402c4b9ec8badcbb5c1eb75481f7c20a36e85461f8a3d4
-SHA256 (0002-py39.patch) = 9196e74a2f53bc29ce7674f949c2345891632a6423284d47f73d86773a8b287d
+RWSagIOpLGJF30dfqZcraKdzpKYDwDyAtzeCtg/QuMnQYSFJ1Y4BLPHy9B3Vkk9vLk+FaQgBC5dJM3mmK+tJTvpR9tnjrirUnAk=
+SHA256 (Pkgfile) = 8a0d95c8605bf38c7d31be6aff4295bfa714047f7967eb2cc03214833bc3499f
+SHA256 (.footprint) = 1b177ce982dec7d6c9ca5be89a724a4c9bc7eb4316c070fd04f6fc352fe07ecc
+SHA256 (python3-babel-2.9.1.tar.gz) = 96102878b273d0160c210d9323406d26c4a5cf0f5d3a0097a059836a624231f9
+SHA256 (cldr-common-37.0.zip) = ba93f5ba256a61a6f8253397c6c4b1a9b9e77531f013cc7ffa7977b5f7e4da57
diff --git a/python3-babel/0001-py39.patch b/python3-babel/0001-py39.patch
deleted file mode 100644
index d0c594eba..000000000
--- a/python3-babel/0001-py39.patch
+++ /dev/null
@@ -1,101 +0,0 @@
-From 167b71421f113e2210e4deefef5020402492e5be Mon Sep 17 00:00:00 2001
-From: Felix Schwarz <felix.schwarz at oss.schwarz.eu>
-Date: Tue, 5 May 2020 09:58:01 +0200
-Subject: [PATCH] stop using deprecated ElementTree methods "getchildren()" and
- "getiterator()"
-
-Both methods were removed in Python 3.9 as mentioned in the release notes:
-
-> Methods getchildren() and getiterator() of classes ElementTree and Element in
-> the ElementTree module have been removed. They were deprecated in Python 3.2.
-> Use iter(x) or list(x) instead of x.getchildren() and x.iter() or
-> list(x.iter()) instead of x.getiterator().
----
- scripts/import_cldr.py | 18 +++++++++---------
- 1 file changed, 9 insertions(+), 9 deletions(-)
-
-diff --git a/scripts/import_cldr.py b/scripts/import_cldr.py
-index 8993b68e..2ed3af91 100755
---- a/scripts/import_cldr.py
-+++ b/scripts/import_cldr.py
-@@ -598,7 +598,7 @@ def parse_calendar_months(data, calendar):
-         for width in ctxt.findall('monthWidth'):
-             width_type = width.attrib['type']
-             widths = ctxts.setdefault(width_type, {})
--            for elem in width.getiterator():
-+            for elem in width.iter():
-                 if elem.tag == 'month':
-                     _import_type_text(widths, elem, int(elem.attrib['type']))
-                 elif elem.tag == 'alias':
-@@ -616,7 +616,7 @@ def parse_calendar_days(data, calendar):
-         for width in ctxt.findall('dayWidth'):
-             width_type = width.attrib['type']
-             widths = ctxts.setdefault(width_type, {})
--            for elem in width.getiterator():
-+            for elem in width.iter():
-                 if elem.tag == 'day':
-                     _import_type_text(widths, elem, weekdays[elem.attrib['type']])
-                 elif elem.tag == 'alias':
-@@ -634,7 +634,7 @@ def parse_calendar_quarters(data, calendar):
-         for width in ctxt.findall('quarterWidth'):
-             width_type = width.attrib['type']
-             widths = ctxts.setdefault(width_type, {})
--            for elem in width.getiterator():
-+            for elem in width.iter():
-                 if elem.tag == 'quarter':
-                     _import_type_text(widths, elem, int(elem.attrib['type']))
-                 elif elem.tag == 'alias':
-@@ -649,7 +649,7 @@ def parse_calendar_eras(data, calendar):
-     for width in calendar.findall('eras/*'):
-         width_type = NAME_MAP[width.tag]
-         widths = eras.setdefault(width_type, {})
--        for elem in width.getiterator():
-+        for elem in width.iter():
-             if elem.tag == 'era':
-                 _import_type_text(widths, elem, type=int(elem.attrib.get('type')))
-             elif elem.tag == 'alias':
-@@ -676,7 +676,7 @@ def parse_calendar_periods(data, calendar):
- def parse_calendar_date_formats(data, calendar):
-     date_formats = data.setdefault('date_formats', {})
-     for format in calendar.findall('dateFormats'):
--        for elem in format.getiterator():
-+        for elem in format.iter():
-             if elem.tag == 'dateFormatLength':
-                 type = elem.attrib.get('type')
-                 if _should_skip_elem(elem, type, date_formats):
-@@ -696,7 +696,7 @@ def parse_calendar_date_formats(data, calendar):
- def parse_calendar_time_formats(data, calendar):
-     time_formats = data.setdefault('time_formats', {})
-     for format in calendar.findall('timeFormats'):
--        for elem in format.getiterator():
-+        for elem in format.iter():
-             if elem.tag == 'timeFormatLength':
-                 type = elem.attrib.get('type')
-                 if _should_skip_elem(elem, type, time_formats):
-@@ -717,7 +717,7 @@ def parse_calendar_datetime_skeletons(data, calendar):
-     datetime_formats = data.setdefault('datetime_formats', {})
-     datetime_skeletons = data.setdefault('datetime_skeletons', {})
-     for format in calendar.findall('dateTimeFormats'):
--        for elem in format.getiterator():
-+        for elem in format.iter():
-             if elem.tag == 'dateTimeFormatLength':
-                 type = elem.attrib.get('type')
-                 if _should_skip_elem(elem, type, datetime_formats):
-@@ -880,7 +880,7 @@ def parse_interval_formats(data, tree):
-             interval_formats[None] = elem.text
-         elif elem.tag == "intervalFormatItem":
-             skel_data = interval_formats.setdefault(elem.attrib["id"], {})
--            for item_sub in elem.getchildren():
-+            for item_sub in elem:
-                 if item_sub.tag == "greatestDifference":
-                     skel_data[item_sub.attrib["id"]] = split_interval_pattern(item_sub.text)
-                 else:
-@@ -903,7 +903,7 @@ def parse_currency_formats(data, tree):
-                     type = '%s:%s' % (type, curr_length_type)
-                 if _should_skip_elem(elem, type, currency_formats):
-                     continue
--                for child in elem.getiterator():
-+                for child in elem.iter():
-                     if child.tag == 'alias':
-                         currency_formats[type] = Alias(
-                             _translate_alias(['currency_formats', elem.attrib['type']],
diff --git a/python3-babel/0002-py39.patch b/python3-babel/0002-py39.patch
deleted file mode 100644
index 8a90166ec..000000000
--- a/python3-babel/0002-py39.patch
+++ /dev/null
@@ -1,68 +0,0 @@
-From 7bdaa28a55e8d8228d5434effa4b1473ab7b3669 Mon Sep 17 00:00:00 2001
-From: Felix Schwarz <felix.schwarz at oss.schwarz.eu>
-Date: Tue, 5 May 2020 08:05:56 +0000
-Subject: [PATCH] fix tests when using Python 3.9a6
-
-In Python 3.9a6 integer values for future flags were changed to prevent
-collision with compiler flags. We need to retrieve these at runtime so
-the test suite works with Python <= 3.8 as well as Python 3.9.
----
- tests/test_util.py | 17 ++++++++++++-----
- 1 file changed, 12 insertions(+), 5 deletions(-)
-
-diff --git a/tests/test_util.py b/tests/test_util.py
-index a6a4450c..b9343aaa 100644
---- a/tests/test_util.py
-+++ b/tests/test_util.py
-@@ -11,6 +11,7 @@
- # individuals. For the exact contribution history, see the revision
- # history and logs, available at http://babel.edgewall.org/log/.
- 
-+import __future__
- import unittest
- 
- import pytest
-@@ -20,6 +21,12 @@
- from babel.util import parse_future_flags
- 
- 
-+class _FF:
-+    division         = __future__.division.compiler_flag
-+    print_function   = __future__.print_function.compiler_flag
-+    with_statement   = __future__.with_statement.compiler_flag
-+    unicode_literals = __future__.unicode_literals.compiler_flag
-+
- def test_distinct():
-     assert list(util.distinct([1, 2, 1, 3, 4, 4])) == [1, 2, 3, 4]
-     assert list(util.distinct('foobar')) == ['f', 'o', 'b', 'a', 'r']
-@@ -70,25 +77,25 @@ def test_parse_encoding_non_ascii():
- from __future__ import print_function,
-     division, with_statement,
-     unicode_literals
--''', 0x10000 | 0x2000 | 0x8000 | 0x20000),
-+''', _FF.print_function | _FF.division | _FF.with_statement | _FF.unicode_literals),
-     ('''
- from __future__ import print_function, division
- print('hello')
--''', 0x10000 | 0x2000),
-+''', _FF.print_function | _FF.division),
-     ('''
- from __future__ import print_function, division, unknown,,,,,
- print 'hello'
--''', 0x10000 | 0x2000),
-+''', _FF.print_function | _FF.division),
-     ('''
- from __future__ import (
-     print_function,
-     division)
--''', 0x10000 | 0x2000),
-+''', _FF.print_function | _FF.division),
-     ('''
- from __future__ import \\
-     print_function, \\
-     division
--''', 0x10000 | 0x2000),
-+''', _FF.print_function | _FF.division),
- ])
- def test_parse_future(source, result):
-     fp = BytesIO(source.encode('latin-1'))
diff --git a/python3-babel/Pkgfile b/python3-babel/Pkgfile
index d45b43a97..75898f998 100644
--- a/python3-babel/Pkgfile
+++ b/python3-babel/Pkgfile
@@ -4,13 +4,12 @@
 # Depends on: python3-pytz python3-setuptools
 
 name=python3-babel
-version=2.8.0
+version=2.9.1
 release=1
-cldrver=36.0 # $SRC/babel-$version/scripts/download_import_cldr.py
+cldrver=37.0 # $SRC/babel-$version/scripts/download_import_cldr.py
 
 source=(https://github.com/python-babel/babel/archive/v$version/$name-$version.tar.gz
-  https://unicode.org/Public/cldr/${cldrver::2}/cldr-common-$cldrver.zip
-  0001-py39.patch 0002-py39.patch)
+  https://unicode.org/Public/cldr/${cldrver::2}/cldr-common-$cldrver.zip)
 
 unpack_source() {
   for file in ${source[@]}; do
@@ -28,11 +27,9 @@ unpack_source() {
 build() {
   cd babel-$version
 
-  patch -Np1 -i $SRC/0001-py39.patch
-  patch -Np1 -i $SRC/0002-py39.patch
-  python3 setup.py import_cldr
-  python3 setup.py build
-  python3 setup.py install --root=$PKG \
+  /usr/bin/python3 setup.py import_cldr
+  /usr/bin/python3 setup.py build
+  /usr/bin/python3 setup.py install --root=$PKG \
     --optimize=1 \
     --skip-build
   mv $PKG/usr/bin/pybabel $PKG/usr/bin/py3babel
diff --git a/python3-babel/import.patch b/python3-babel/import.patch
deleted file mode 100644
index 4a45de86b..000000000
--- a/python3-babel/import.patch
+++ /dev/null
@@ -1,80 +0,0 @@
-From 2a826bb1ad9996a1c1e2d3e86a493d01d7f12c09 Mon Sep 17 00:00:00 2001
-From: Felix Schwarz <felix.schwarz at oss.schwarz.eu>
-Date: Tue, 5 May 2020 21:32:52 +0000
-Subject: [PATCH] simplify iteration code in "import_cldr.py"
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-As Miro Hrončok pointed out we don't need ".iter()" in the script.
----
- scripts/import_cldr.py | 14 +++++++-------
- 1 file changed, 7 insertions(+), 7 deletions(-)
-
-diff --git a/scripts/import_cldr.py b/scripts/import_cldr.py
-index 2ed3af91..7ea6481a 100755
---- a/scripts/import_cldr.py
-+++ b/scripts/import_cldr.py
-@@ -598,7 +598,7 @@ def parse_calendar_months(data, calendar):
-         for width in ctxt.findall('monthWidth'):
-             width_type = width.attrib['type']
-             widths = ctxts.setdefault(width_type, {})
--            for elem in width.iter():
-+            for elem in width:
-                 if elem.tag == 'month':
-                     _import_type_text(widths, elem, int(elem.attrib['type']))
-                 elif elem.tag == 'alias':
-@@ -616,7 +616,7 @@ def parse_calendar_days(data, calendar):
-         for width in ctxt.findall('dayWidth'):
-             width_type = width.attrib['type']
-             widths = ctxts.setdefault(width_type, {})
--            for elem in width.iter():
-+            for elem in width:
-                 if elem.tag == 'day':
-                     _import_type_text(widths, elem, weekdays[elem.attrib['type']])
-                 elif elem.tag == 'alias':
-@@ -634,7 +634,7 @@ def parse_calendar_quarters(data, calendar):
-         for width in ctxt.findall('quarterWidth'):
-             width_type = width.attrib['type']
-             widths = ctxts.setdefault(width_type, {})
--            for elem in width.iter():
-+            for elem in width:
-                 if elem.tag == 'quarter':
-                     _import_type_text(widths, elem, int(elem.attrib['type']))
-                 elif elem.tag == 'alias':
-@@ -649,7 +649,7 @@ def parse_calendar_eras(data, calendar):
-     for width in calendar.findall('eras/*'):
-         width_type = NAME_MAP[width.tag]
-         widths = eras.setdefault(width_type, {})
--        for elem in width.iter():
-+        for elem in width:
-             if elem.tag == 'era':
-                 _import_type_text(widths, elem, type=int(elem.attrib.get('type')))
-             elif elem.tag == 'alias':
-@@ -676,7 +676,7 @@ def parse_calendar_periods(data, calendar):
- def parse_calendar_date_formats(data, calendar):
-     date_formats = data.setdefault('date_formats', {})
-     for format in calendar.findall('dateFormats'):
--        for elem in format.iter():
-+        for elem in format:
-             if elem.tag == 'dateFormatLength':
-                 type = elem.attrib.get('type')
-                 if _should_skip_elem(elem, type, date_formats):
-@@ -696,7 +696,7 @@ def parse_calendar_date_formats(data, calendar):
- def parse_calendar_time_formats(data, calendar):
-     time_formats = data.setdefault('time_formats', {})
-     for format in calendar.findall('timeFormats'):
--        for elem in format.iter():
-+        for elem in format:
-             if elem.tag == 'timeFormatLength':
-                 type = elem.attrib.get('type')
-                 if _should_skip_elem(elem, type, time_formats):
-@@ -717,7 +717,7 @@ def parse_calendar_datetime_skeletons(data, calendar):
-     datetime_formats = data.setdefault('datetime_formats', {})
-     datetime_skeletons = data.setdefault('datetime_skeletons', {})
-     for format in calendar.findall('dateTimeFormats'):
--        for elem in format.iter():
-+        for elem in format:
-             if elem.tag == 'dateTimeFormatLength':
-                 type = elem.attrib.get('type')
-                 if _should_skip_elem(elem, type, datetime_formats):


More information about the crux-commits mailing list