python-theano fails to build with Python 3.9.0a3. Running Sphinx v2.2.2 Configuration error: There is a programmable error in your configuration file: Traceback (most recent call last): File "/builddir/build/BUILD/Theano-rel-1.0.4/theano/compat/__init__.py", line 10, in <module> from collections.abc import (OrderedDict, MutableMapping as DictMixin, ImportError: cannot import name 'OrderedDict' from 'collections.abc' (/usr/lib64/python3.9/collections/abc.py) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/usr/lib/python3.9/site-packages/sphinx/config.py", line 361, in eval_config_file execfile_(filename, namespace) File "/usr/lib/python3.9/site-packages/sphinx/util/pycompat.py", line 81, in execfile_ exec(code, _globals) File "/builddir/build/BUILD/Theano-rel-1.0.4/doc/conf.py", line 25, in <module> import theano File "/builddir/build/BUILD/Theano-rel-1.0.4/theano/__init__.py", line 88, in <module> from theano.configdefaults import config File "/builddir/build/BUILD/Theano-rel-1.0.4/theano/configdefaults.py", line 17, in <module> from theano.configparser import (AddConfigVar, BoolParam, ConfigParam, EnumStr, File "/builddir/build/BUILD/Theano-rel-1.0.4/theano/configparser.py", line 16, in <module> from theano.compat import configparser as ConfigParser File "/builddir/build/BUILD/Theano-rel-1.0.4/theano/compat/__init__.py", line 16, in <module> from collections import (OrderedDict, MutableMapping as DictMixin, ImportError: cannot import name 'MutableMapping' from 'collections' (/usr/lib64/python3.9/collections/__init__.py) This is caused by trying to import OrderedDict and MutableMapping from the same namespace. I've tried to explain this upstream https://github.com/Theano/Theano/pull/6664#issuecomment-581845517 For the build logs, see: https://copr-be.cloud.fedoraproject.org/results/@python/python3.9/fedora-rawhide-x86_64/01219951-python-theano/ For all our attempts to build python-theano with Python 3.9, see: https://copr.fedorainfracloud.org/coprs/g/python/python3.9/package/python-theano/ Testing and mass rebuild of packages is happening in copr. You can follow these instructions to test locally in mock if your package builds with Python 3.9: https://copr.fedorainfracloud.org/coprs/g/python/python3.9/ Let us know here if you have any questions. Python 3.9 will be included in Fedora 33. To make that update smoother, we're building Fedora packages with early pre-releases of Python 3.9. A build failure prevents us from testing all dependent packages (transitive [Build]Requires), so if this package is required a lot, it's important for us to get it fixed soon. We'd appreciate help from the people who know this package best, but if you don't want to work on this now, let us know so we can try to work around it on our side.
Upstream fix: https://github.com/Theano/Theano/pull/6741
I have added this patch. I also attempted a Rawhide build, but that failed when the builder ran out of memory. :-( I'll attempt it again, but hopefully you can proceed with your python 3.9 work now.
Unfortunately, there is one more: Traceback (most recent call last): File "/usr/lib/python3.9/site-packages/sphinx/config.py", line 361, in eval_config_file execfile_(filename, namespace) File "/usr/lib/python3.9/site-packages/sphinx/util/pycompat.py", line 81, in execfile_ exec(code, _globals) File "/builddir/build/BUILD/Theano-rel-1.0.4/doc/conf.py", line 25, in <module> import theano File "/builddir/build/BUILD/Theano-rel-1.0.4/theano/__init__.py", line 124, in <module> from theano.scan_module import (scan, map, reduce, foldl, foldr, clone, File "/builddir/build/BUILD/Theano-rel-1.0.4/theano/scan_module/__init__.py", line 41, in <module> from theano.scan_module import scan_opt File "/builddir/build/BUILD/Theano-rel-1.0.4/theano/scan_module/scan_opt.py", line 60, in <module> from theano import tensor, scalar File "/builddir/build/BUILD/Theano-rel-1.0.4/theano/tensor/__init__.py", line 8, in <module> from theano.tensor.basic import * File "/builddir/build/BUILD/Theano-rel-1.0.4/theano/tensor/basic.py", line 20, in <module> from theano.scalar import int32 as int32_t File "/builddir/build/BUILD/Theano-rel-1.0.4/theano/scalar/__init__.py", line 3, in <module> from .basic import * File "/builddir/build/BUILD/Theano-rel-1.0.4/theano/scalar/basic.py", line 1660, in <module> maximum = Maximum(upcast_out, name='maximum') File "/builddir/build/BUILD/Theano-rel-1.0.4/theano/scalar/basic.py", line 1031, in __init__ if not isinstance(output_types_preference, collections.Callable): AttributeError: module 'collections' has no attribute 'Callable'
And even then: Traceback (most recent call last): File "/usr/lib/python3.9/site-packages/sphinx/config.py", line 361, in eval_config_file execfile_(filename, namespace) File "/usr/lib/python3.9/site-packages/sphinx/util/pycompat.py", line 81, in execfile_ exec(code, _globals) File "/builddir/build/BUILD/Theano-rel-1.0.4/doc/conf.py", line 25, in <module> import theano File "/builddir/build/BUILD/Theano-rel-1.0.4/theano/__init__.py", line 124, in <module> from theano.scan_module import (scan, map, reduce, foldl, foldr, clone, File "/builddir/build/BUILD/Theano-rel-1.0.4/theano/scan_module/__init__.py", line 41, in <module> from theano.scan_module import scan_opt File "/builddir/build/BUILD/Theano-rel-1.0.4/theano/scan_module/scan_opt.py", line 60, in <module> from theano import tensor, scalar File "/builddir/build/BUILD/Theano-rel-1.0.4/theano/tensor/__init__.py", line 38, in <module> from theano.tensor import nnet # used for softmax, sigmoid, etc. File "/builddir/build/BUILD/Theano-rel-1.0.4/theano/tensor/nnet/__init__.py", line 23, in <module> from . import opt File "/builddir/build/BUILD/Theano-rel-1.0.4/theano/tensor/nnet/opt.py", line 11, in <module> from theano.tensor.nnet.corr import ( File "/builddir/build/BUILD/Theano-rel-1.0.4/theano/tensor/nnet/corr.py", line 13, in <module> from theano.tensor.nnet.abstract_conv import get_conv_output_shape File "/builddir/build/BUILD/Theano-rel-1.0.4/theano/tensor/nnet/abstract_conv.py", line 9, in <module> from fractions import gcd ImportError: cannot import name 'gcd' from 'fractions' (/usr/lib64/python3.9/fractions.py)
Ie updated https://github.com/Theano/Theano/pull/6741 - it now passes the docs build. Running %check now...
It builds with the PR.
I pushed the changes and launched another Rawhide build. With luck it won't be assigned to an ARM builder...
This bug appears to have been reported against 'rawhide' during the Fedora 32 development cycle. Changing version to 32.
This comment is mass posted to all bugs blocking the Python 3.9 tracker, sorry if it is not 100 % relevant. When in doubt, please ask. The Python 3.9 rebuild is in progress in a Koji side tag. If you fix this bug, please don't rebuild the package in regular rawhide, but do it in the side tag with: $ fedpkg build --target=f33-python The rebuild is progressing slowly and it is possible this package won't have all the required build dependencies yet. If that's the case, please just leave the fix committed and pushed and we will eventually rebuild it for you. You are not asked to go and try rebuild all the missing dependencies yourself. If you know there is a bootstrap loop in the dependencies, let me know and we can untangle it together. If you want to test your fix or reproduce the failure, you can still use the Copr repo mentioned in the initial comment of this bug: https://copr.fedorainfracloud.org/coprs/g/python/python3.9/
Theano is currently blocked by flake8/pyflakes. Would you accept a patch to drop the build dependency on flake8? I think that linting is not that useful in RPM build and a lot of flake errors are already ignored by an existing patch.
Yes, absolutely. I had meant to do that already, but am currently buried under big piles of $DAYJOB work.
Python 3.9 update: The f33-python side tag is currently being merged. New builds in f33-python are no longer possible, but python3 is not yet updated to Python 3.9 in rawhide. You can check when Python is Python 3.9 with: $ koji wait-repo f33-build --build python3.9-3.9.0~b1-3.fc3 And build the packages normally after that.
This is a bulk close of Python 3.9 bugzillas of packages that successfully built. If this remained open for a reason, I am sorry and feel free to reopen.