xonsh fails to build with Python 3.10.0a2. =================================== FAILURES =================================== [31m[1m________________________ test_call_macro_ast_eval_expr _________________________[0m [94mdef[39;49;00m [92mtest_call_macro_ast_eval_expr[39;49;00m(): [94mdef[39;49;00m [92mf[39;49;00m(x: ([33m"[39;49;00m[33mast[39;49;00m[33m"[39;49;00m, [33m"[39;49;00m[33meval[39;49;00m[33m"[39;49;00m)): [94mreturn[39;49;00m x > rtn = call_macro(f, [[33m"[39;49;00m[33mx == 5[39;49;00m[33m"[39;49;00m], {}, [94mNone[39;49;00m) [1m[31m/builddir/build/BUILD/xonsh-0.9.21/tests/test_builtins.py[0m:333: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ [1m[31m/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/built_ins.py[0m:1220: in call_macro arg = convert_macro_arg( [1m[31m/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/built_ins.py[0m:1129: in convert_macro_arg kind = _convert_kind_flag(kind) _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ x = "('ast', 'eval')" [94mdef[39;49;00m [92m_convert_kind_flag[39;49;00m(x): [33m"""Puts a kind flag (string) a canonical form."""[39;49;00m x = x.lower() kind = MACRO_FLAG_KINDS.get(x, [94mNone[39;49;00m) [94mif[39;49;00m kind [95mis[39;49;00m [94mNone[39;49;00m: > [94mraise[39;49;00m [96mTypeError[39;49;00m([33m"[39;49;00m[33m{0!r}[39;49;00m[33m not a recognized macro type.[39;49;00m[33m"[39;49;00m.format(x)) [1m[31mE TypeError: "('ast', 'eval')" not a recognized macro type.[0m [1m[31m/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/built_ins.py[0m:1097: TypeError [31m[1m_______________________ test_call_macro_ast_single_expr ________________________[0m [94mdef[39;49;00m [92mtest_call_macro_ast_single_expr[39;49;00m(): [94mdef[39;49;00m [92mf[39;49;00m(x: ([33m"[39;49;00m[33mast[39;49;00m[33m"[39;49;00m, [33m"[39;49;00m[33msingle[39;49;00m[33m"[39;49;00m)): [94mreturn[39;49;00m x > rtn = call_macro(f, [[33m"[39;49;00m[33mx == 5[39;49;00m[33m"[39;49;00m], {}, [94mNone[39;49;00m) [1m[31m/builddir/build/BUILD/xonsh-0.9.21/tests/test_builtins.py[0m:341: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ [1m[31m/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/built_ins.py[0m:1220: in call_macro arg = convert_macro_arg( [1m[31m/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/built_ins.py[0m:1129: in convert_macro_arg kind = _convert_kind_flag(kind) _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ x = "('ast', 'single')" [94mdef[39;49;00m [92m_convert_kind_flag[39;49;00m(x): [33m"""Puts a kind flag (string) a canonical form."""[39;49;00m x = x.lower() kind = MACRO_FLAG_KINDS.get(x, [94mNone[39;49;00m) [94mif[39;49;00m kind [95mis[39;49;00m [94mNone[39;49;00m: > [94mraise[39;49;00m [96mTypeError[39;49;00m([33m"[39;49;00m[33m{0!r}[39;49;00m[33m not a recognized macro type.[39;49;00m[33m"[39;49;00m.format(x)) [1m[31mE TypeError: "('ast', 'single')" not a recognized macro type.[0m [1m[31m/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/built_ins.py[0m:1097: TypeError [31m[1m________________________ test_call_macro_ast_exec_expr _________________________[0m [94mdef[39;49;00m [92mtest_call_macro_ast_exec_expr[39;49;00m(): [94mdef[39;49;00m [92mf[39;49;00m(x: ([33m"[39;49;00m[33mast[39;49;00m[33m"[39;49;00m, [33m"[39;49;00m[33mexec[39;49;00m[33m"[39;49;00m)): [94mreturn[39;49;00m x > rtn = call_macro(f, [[33m"[39;49;00m[33mx == 5[39;49;00m[33m"[39;49;00m], {}, [94mNone[39;49;00m) [1m[31m/builddir/build/BUILD/xonsh-0.9.21/tests/test_builtins.py[0m:349: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ [1m[31m/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/built_ins.py[0m:1220: in call_macro arg = convert_macro_arg( [1m[31m/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/built_ins.py[0m:1129: in convert_macro_arg kind = _convert_kind_flag(kind) _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ x = "('ast', 'exec')" [94mdef[39;49;00m [92m_convert_kind_flag[39;49;00m(x): [33m"""Puts a kind flag (string) a canonical form."""[39;49;00m x = x.lower() kind = MACRO_FLAG_KINDS.get(x, [94mNone[39;49;00m) [94mif[39;49;00m kind [95mis[39;49;00m [94mNone[39;49;00m: > [94mraise[39;49;00m [96mTypeError[39;49;00m([33m"[39;49;00m[33m{0!r}[39;49;00m[33m not a recognized macro type.[39;49;00m[33m"[39;49;00m.format(x)) [1m[31mE TypeError: "('ast', 'exec')" not a recognized macro type.[0m [1m[31m/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/built_ins.py[0m:1097: TypeError [31m[1m______________________ test_call_macro_ast_eval_statement ______________________[0m [94mdef[39;49;00m [92mtest_call_macro_ast_eval_statement[39;49;00m(): [94mdef[39;49;00m [92mf[39;49;00m(x: ([33m"[39;49;00m[33mast[39;49;00m[33m"[39;49;00m, [33m"[39;49;00m[33meval[39;49;00m[33m"[39;49;00m)): [94mreturn[39;49;00m x [94mtry[39;49;00m: > call_macro(f, [[33m"[39;49;00m[33mx = 5[39;49;00m[33m"[39;49;00m], {}, [94mNone[39;49;00m) [1m[31m/builddir/build/BUILD/xonsh-0.9.21/tests/test_builtins.py[0m:358: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ [1m[31m/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/built_ins.py[0m:1220: in call_macro arg = convert_macro_arg( [1m[31m/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/built_ins.py[0m:1129: in convert_macro_arg kind = _convert_kind_flag(kind) _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ x = "('ast', 'eval')" [94mdef[39;49;00m [92m_convert_kind_flag[39;49;00m(x): [33m"""Puts a kind flag (string) a canonical form."""[39;49;00m x = x.lower() kind = MACRO_FLAG_KINDS.get(x, [94mNone[39;49;00m) [94mif[39;49;00m kind [95mis[39;49;00m [94mNone[39;49;00m: > [94mraise[39;49;00m [96mTypeError[39;49;00m([33m"[39;49;00m[33m{0!r}[39;49;00m[33m not a recognized macro type.[39;49;00m[33m"[39;49;00m.format(x)) [1m[31mE TypeError: "('ast', 'eval')" not a recognized macro type.[0m [1m[31m/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/built_ins.py[0m:1097: TypeError [31m[1m_____________________ test_call_macro_ast_single_statement _____________________[0m [94mdef[39;49;00m [92mtest_call_macro_ast_single_statement[39;49;00m(): [94mdef[39;49;00m [92mf[39;49;00m(x: ([33m"[39;49;00m[33mast[39;49;00m[33m"[39;49;00m, [33m"[39;49;00m[33msingle[39;49;00m[33m"[39;49;00m)): [94mreturn[39;49;00m x > rtn = call_macro(f, [[33m"[39;49;00m[33mx = 5[39;49;00m[33m"[39;49;00m], {}, [94mNone[39;49;00m) [1m[31m/builddir/build/BUILD/xonsh-0.9.21/tests/test_builtins.py[0m:372: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ [1m[31m/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/built_ins.py[0m:1220: in call_macro arg = convert_macro_arg( [1m[31m/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/built_ins.py[0m:1129: in convert_macro_arg kind = _convert_kind_flag(kind) _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ x = "('ast', 'single')" [94mdef[39;49;00m [92m_convert_kind_flag[39;49;00m(x): [33m"""Puts a kind flag (string) a canonical form."""[39;49;00m x = x.lower() kind = MACRO_FLAG_KINDS.get(x, [94mNone[39;49;00m) [94mif[39;49;00m kind [95mis[39;49;00m [94mNone[39;49;00m: > [94mraise[39;49;00m [96mTypeError[39;49;00m([33m"[39;49;00m[33m{0!r}[39;49;00m[33m not a recognized macro type.[39;49;00m[33m"[39;49;00m.format(x)) [1m[31mE TypeError: "('ast', 'single')" not a recognized macro type.[0m [1m[31m/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/built_ins.py[0m:1097: TypeError [31m[1m______________________ test_call_macro_ast_exec_statement ______________________[0m [94mdef[39;49;00m [92mtest_call_macro_ast_exec_statement[39;49;00m(): [94mdef[39;49;00m [92mf[39;49;00m(x: ([33m"[39;49;00m[33mast[39;49;00m[33m"[39;49;00m, [33m"[39;49;00m[33mexec[39;49;00m[33m"[39;49;00m)): [94mreturn[39;49;00m x > rtn = call_macro(f, [[33m"[39;49;00m[33mx = 5[39;49;00m[33m"[39;49;00m], {}, [94mNone[39;49;00m) [1m[31m/builddir/build/BUILD/xonsh-0.9.21/tests/test_builtins.py[0m:380: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ [1m[31m/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/built_ins.py[0m:1220: in call_macro arg = convert_macro_arg( [1m[31m/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/built_ins.py[0m:1129: in convert_macro_arg kind = _convert_kind_flag(kind) _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ x = "('ast', 'exec')" [94mdef[39;49;00m [92m_convert_kind_flag[39;49;00m(x): [33m"""Puts a kind flag (string) a canonical form."""[39;49;00m x = x.lower() kind = MACRO_FLAG_KINDS.get(x, [94mNone[39;49;00m) [94mif[39;49;00m kind [95mis[39;49;00m [94mNone[39;49;00m: > [94mraise[39;49;00m [96mTypeError[39;49;00m([33m"[39;49;00m[33m{0!r}[39;49;00m[33m not a recognized macro type.[39;49;00m[33m"[39;49;00m.format(x)) [1m[31mE TypeError: "('ast', 'exec')" not a recognized macro type.[0m [1m[31m/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/built_ins.py[0m:1097: TypeError =========================== short test summary info ============================ FAILED tests/test_builtins.py::test_call_macro_ast_eval_expr - TypeError: "('... FAILED tests/test_builtins.py::test_call_macro_ast_single_expr - TypeError: "... FAILED tests/test_builtins.py::test_call_macro_ast_exec_expr - TypeError: "('... FAILED tests/test_builtins.py::test_call_macro_ast_eval_statement - TypeError... FAILED tests/test_builtins.py::test_call_macro_ast_single_statement - TypeErr... FAILED tests/test_builtins.py::test_call_macro_ast_exec_statement - TypeError... [31m====== [31m[1m6 failed[0m, [32m1982 passed[0m, [33m16 skipped[0m, [33m1 xpassed[0m[31m in 113.48s (0:01:53)[0m[31m =======[0m Traceback (most recent call last): File "/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/bin/xonsh", line 33, in <module> sys.exit(load_entry_point('xonsh==0.9.21', 'console_scripts', 'xonsh')()) File "/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/main.py", line 426, in main _failback_to_other_shells(args, err) File "/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/main.py", line 373, in _failback_to_other_shells raise err File "/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/main.py", line 424, in main sys.exit(main_xonsh(args)) File "/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/main.py", line 471, in main_xonsh run_script_with_cache( File "/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/codecache.py", line 162, in run_script_with_cache run_compiled_code(ccode, glb, loc, mode) File "/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/codecache.py", line 67, in run_compiled_code func(code, glb, loc) File "run-tests.xsh", line 26, in <module> ![pytest @(replace_args(0)) @(ignores)] File "/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/built_ins.py", line 1019, in subproc_captured_hiddenobject return run_subproc(cmds, captured="hiddenobject") File "/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/built_ins.py", line 978, in run_subproc command.end() File "/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/proc.py", line 2150, in end self._end(tee_output=tee_output) File "/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/proc.py", line 2169, in _end self._raise_subproc_error() File "/builddir/build/BUILDROOT/xonsh-0.9.21-1.fc34.x86_64/usr/lib/python3.10/site-packages/xonsh/proc.py", line 2295, in _raise_subproc_error raise subprocess.CalledProcessError(rtn, spec.args, output=self.output) subprocess.CalledProcessError: Command '['pytest', '--ignore', 'tests/test_parser.py', '--ignore', 'tests/test_main.py', '--ignore', 'tests/test_ptk_highlight.py']' returned non-zero exit status 1. error: Bad exit status from /var/tmp/rpm-tmp.vZ9Qgv (%check) Bad exit status from /var/tmp/rpm-tmp.vZ9Qgv (%check) For the build logs, see: https://copr-be.cloud.fedoraproject.org/results/@python/python3.10/fedora-rawhide-x86_64/01773536-xonsh/ For all our attempts to build xonsh with Python 3.10, see: https://copr.fedorainfracloud.org/coprs/g/python/python3.10/package/xonsh/ 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.10: https://copr.fedorainfracloud.org/coprs/g/python/python3.10/ Let us know here if you have any questions. Python 3.10 will be included in Fedora 35. To make that update smoother, we're building Fedora packages with early pre-releases of Python 3.10. 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.
Hello, is there any update on this? It blocks testing of 2 other packages (python-virtualenv, asv) with Python 3.10. Thank you.
xonsh tests of virtualenv are optional. I recommend disabling them for Python 3.10, as xonsh is likely to not be fixed in time for the actual bootstrap, based on my previous experience.
Thank you for the hint Miro. With disabled failing tests xonsh, python-virtualenv and asv are building just fine.
Hi sorry. I just finished getting my degree this week. This package has been incredibly difficult to maintain as the Python versions tally up. Tests always break, and upstream appears to be a few Python releases behind. I suspect that the upstream maintainer runs a Debian-like stable distribution. I'm going to try to figure out some upstream patches. In the meantime it's very acceptable that this package should not block anything. If the package continues being un-maintainable I might retire it.
This bug appears to have been reported against 'rawhide' during the Fedora 34 development cycle. Changing version to 34.
This is a mass-posted update. Sorry if it is not 100% accurate to this bugzilla. The Python 3.10 rebuild is in progress in a Koji side tag. If you manage to fix the problem, please commit the fix in the rawhide branch, but don't build the package in regular rawhide. You can either build the package in the side tag, with: $ fedpkg build --target=f35-python Or you can the build and we will eventually build it for you. Note that the rebuild is still in progress, so not all (build) dependencies of this package might be available right away. Thanks. See also https://fedoraproject.org/wiki/Changes/Python3.10 If you have general questions about the rebuild, please use this mailing list thread: https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org/thread/G47SGOYIQLRDTWGOSLSWERZSSHXDEDH5/
The f35-python side tag has been merged to Rawhide. From now on, build as you would normally build.
*** Bug 1969202 has been marked as a duplicate of this bug. ***
The current failure is: + python -m xonsh run-tests.xsh test Traceback (most recent call last): File "/usr/lib64/python3.10/runpy.py", line 196, in _run_module_as_main return _run_code(code, main_globals, None, File "/usr/lib64/python3.10/runpy.py", line 86, in _run_code exec(code, run_globals) File "/builddir/build/BUILDROOT/xonsh-0.9.26-3.fc35.x86_64/usr/lib/python3.10/site-packages/xonsh/__main__.py", line 3, in <module> main() File "/builddir/build/BUILDROOT/xonsh-0.9.26-3.fc35.x86_64/usr/lib/python3.10/site-packages/xonsh/main.py", line 423, in main _failback_to_other_shells(args, err) File "/builddir/build/BUILDROOT/xonsh-0.9.26-3.fc35.x86_64/usr/lib/python3.10/site-packages/xonsh/main.py", line 370, in _failback_to_other_shells raise err File "/builddir/build/BUILDROOT/xonsh-0.9.26-3.fc35.x86_64/usr/lib/python3.10/site-packages/xonsh/main.py", line 421, in main sys.exit(main_xonsh(args)) File "/builddir/build/BUILDROOT/xonsh-0.9.26-3.fc35.x86_64/usr/lib/python3.10/site-packages/xonsh/main.py", line 475, in main_xonsh run_script_with_cache( File "/builddir/build/BUILDROOT/xonsh-0.9.26-3.fc35.x86_64/usr/lib/python3.10/site-packages/xonsh/codecache.py", line 160, in run_script_with_cache ccode = compile_code(filename, code, execer, glb, loc, mode) File "/builddir/build/BUILDROOT/xonsh-0.9.26-3.fc35.x86_64/usr/lib/python3.10/site-packages/xonsh/codecache.py", line 119, in compile_code ccode = execer.compile(code, glbs=glb, locs=loc, mode=mode, filename=filename) File "/builddir/build/BUILDROOT/xonsh-0.9.26-3.fc35.x86_64/usr/lib/python3.10/site-packages/xonsh/execer.py", line 138, in compile code = compile(tree, filename, mode) TypeError: required field "lineno" missing from alias error: Bad exit status from /var/tmp/rpm-tmp.qDV9Tp (%check)
An update seems to fix this. Will send PR if I don't encounter more trouble.
FEDORA-2021-80a89be54f has been submitted as an update to Fedora 35. https://bodhi.fedoraproject.org/updates/FEDORA-2021-80a89be54f
FEDORA-2021-80a89be54f has been pushed to the Fedora 35 stable repository. If problem still persists, please make note of it in this bug report.