Drop obsolete patches

This commit is contained in:
Benjamin A. Beasley
2023-07-11 01:01:18 -04:00
parent ed2289d1b5
commit 11bba046eb
-19
View File
@@ -39,25 +39,6 @@ Provides: bundled(python3dist(flexcache)) = 0.2
%prep
%autosetup -n Pint-%{version}
# numpy 1.24.x removes np.float np.alen and so on
# These are already fixed upstream
grep -rl "dtype=np\.float" . | xargs sed -i -e 's|dtype=np\.float|dtype=float|'
sed -i pint/testsuite/test_numpy.py \
-e 's|dtype=float32|dtype=np.float32|' \
-e 's|dtype=float64|dtype=np.float64|' \
-e 's|np\.alen|len|' \
%{nil}
# Workaround for https://github.com/hgrecco/pint/issues/1818
sed -i pint/testsuite/__init__.py -e '115s|except TypeError:|except (TypeError, ValueError):|'
# python 3.12 removes deprecated unittest.assertEquals
# This is already fixed upstream
sed -i pint/testsuite/test_contexts.py -e 's|self.assertEquals|self.assertEqual|'
# drop numpy version requirement
sed -i '/@helpers.requires_numpy_at_least("1.16")/d' pint/testsuite/test_quantity.py
# We are not sure where this was bundled from, but we are pretty sure it was
# bundled from somewhere! We are not building HTML documentation, so we do not
# need it.