Created attachment 1562703 [details] Full log from Copr python-pint-0.9-2 fails to build with Python 3.8: ====================================================================== ERROR: test_nonnumeric_magnitudes (test_quantity.TestQuantityToCompact) ---------------------------------------------------------------------- Traceback (most recent call last): File "/builddir/build/BUILD/Pint-0.9/pint/testsuite/test_quantity.py", line 419, in test_nonnumeric_magnitudes self.assertRaises(RuntimeError, self.compareQuantity_compact(x,x)) File "/usr/lib64/python3.8/unittest/case.py", line 799, in assertRaises return context.handle('assertRaises', args, kwargs) File "/usr/lib64/python3.8/unittest/case.py", line 214, in handle callable_obj(*args, **kwargs) TypeError: 'NoneType' object is not callable Full log attached
In 3.7 the tests were emitting a DeprecationWarning that callable cannot be None to assertRaises. Now in Python 3.8 it's an error with https://bugs.python.org/issue34318. pytest -s pint/testsuite/test_quantity.py::TestQuantityToCompact::test_nonnumeric_magnitudes ======================================== test session starts ======================================== platform linux -- Python 3.7.0, pytest-4.0.0, py-1.7.0, pluggy-0.8.0 rootdir: /home/karthi/pint, inifile: plugins: rerunfailures-7.0, repeat-0.8.0, cov-2.6.0, forked-0.2, xdist-1.25.0, httpbin-0.3.0, mock-1.10.0 collected 1 item pint/testsuite/test_quantity.py None . ========================================= warnings summary ========================================== pint/testsuite/test_quantity.py::TestQuantityToCompact::test_nonnumeric_magnitudes /home/karthi/pint/pint/testsuite/test_quantity.py:403: RuntimeWarning: to_compact applied to non numerical types has an undefined behavior. self.assertQuantityAlmostIdentical(q.to_compact(unit=unit), /home/karthi/pint/pint/testsuite/test_quantity.py:458: DeprecationWarning: callable is None self.assertRaises(RuntimeError, self.compareQuantity_compact(x,x)) -- Docs: https://docs.pytest.org/en/latest/warnings.html
Upstream PR to fix the tests and DeprecationWarning on 3.8 : https://github.com/hgrecco/pint/pull/824
Matthias, let's backport the fix?
Yes, makes sense to me.
python-pint still fails to build with Python 3.8.0b2. ====================================================================== ERROR: test_nonnumeric_magnitudes (test_quantity.TestQuantityToCompact) ---------------------------------------------------------------------- Traceback (most recent call last): File "/builddir/build/BUILD/Pint-0.9/pint/testsuite/test_quantity.py", line 419, in test_nonnumeric_magnitudes self.assertRaises(RuntimeError, self.compareQuantity_compact(x,x)) File "/usr/lib64/python3.8/unittest/case.py", line 811, in assertRaises return context.handle('assertRaises', args, kwargs) File "/usr/lib64/python3.8/unittest/case.py", line 197, in handle callable_obj(*args, **kwargs) TypeError: 'NoneType' object is not callable ---------------------------------------------------------------------- Ran 799 tests in 23.263s FAILED (errors=1, skipped=15, expected failures=14) From a quick look at the spec, the patch doesn't seem to be applied.
But when applied, it fails: Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.Oxuw56 + umask 022 + cd /home/churchyard/rpmbuild/fedora-scm/python-pint + cd /home/churchyard/rpmbuild/fedora-scm/python-pint + rm -rf Pint-0.9 + /usr/bin/gzip -dc /home/churchyard/rpmbuild/fedora-scm/python-pint/Pint-0.9.tar.gz + /usr/bin/tar -xof - + STATUS=0 + '[' 0 -ne 0 ']' + cd Pint-0.9 + /usr/bin/chmod -Rf a+rX,u+w,g-w,o-w . + /usr/bin/cat /home/churchyard/rpmbuild/fedora-scm/python-pint/955102b318a4ecc34afd0f366e826ef174fe647b.patch + /usr/bin/patch -p1 -s --fuzz=0 --no-backup-if-mismatch 1 out of 2 hunks FAILED -- saving rejects to file pint/testsuite/test_quantity.py.rej error: Bad exit status from /var/tmp/rpm-tmp.Oxuw56 (%prep)
ugh, will have a look
This bug appears to have been reported against 'rawhide' during the Fedora 31 development cycle. Changing version to '31'.
This bug appears to have been reported against 'rawhide' during the Fedora 31 development cycle. Changing version to 31.
The coordinated rebuild of Python 3.8 has started in the `f32-python` side tag. If you figure out how to rebuild this package, please don't rebuild it in regular rawhide, but use the side tag instead: on branch master: $ fedpkg build --target=f32-python To wait for a build to show up in the side tag, do: $ koji wait-repo f32-python --build=<nvr> Where <nvr> is name-version-release of the source package, e.g. python-foo-1.1-2.fc32. An updated mock config is posted at: http://copr.fedorainfracloud.org/coprs/g/python/python3.8/ Note that it will take a while before the essential packages are rebuilt, so don't expect all your dependencies to be available right away. Thanks. Let us know if you need up to date info, or if you have any questions. PS this message is mass posted to all the bugs that block the PYTHON38 bug. If this is also a Fedora 31 FTBFS bug and you manage to fix it, you can do a f31 build as usual: on branch f31: $ fedpkg build
The f32-python side tag has been merged. In order to rebuild the package, do it in regular rawhide, but please wait until python3-3.8 is tagged: $ koji wait-repo f32-build --build python3-3.8.0~b3-3.fc32 If your built already started in f32-python, after it is finished, please tag it to rawhide with: $ koji tag-build f32-pending <nvr> For example: $ koji tag-build f32-pending libreoffice-6.3.0.4-3.fc32 Thanks! (This comment is mass posted to all bugzillas blocking the PYTHON38 tracking bug.)
(Python 3.8 has landed in the rawhide buildroot.)