You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Traceback (most recent call last):
File "/builddir/build/BUILD/Python-3.11.0a1/Lib/test/test_tools/test_sundry.py", line 43, in test_sundry
import_tool(name)
^^^^^^^^^^^^^^^^^
File "/builddir/build/BUILD/Python-3.11.0a1/Lib/test/test_tools/__init__.py", line 35, in import_toolreturn importlib.import_module(toolname)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/builddir/build/BUILD/Python-3.11.0a1/Lib/importlib/__init__.py", line 126, in import_modulereturn _bootstrap._gcd_import(name[level:], package, level)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "<frozen importlib._bootstrap>", line 1072, in _gcd_import
File "<frozen importlib._bootstrap>", line 1044, in _find_and_load
File "<frozen importlib._bootstrap>", line 1015, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 689, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 894, in exec_module
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File "/builddir/build/BUILD/Python-3.11.0a1/Tools/scripts/freeze_modules.py", line 37, in <module>
sys.exit("ERROR: missing _freeze_module")
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^SystemExit: ERROR: missing _freeze_module
Ran 3 tests in 0.209s
I see in the build log we use Programs/_freeze_module regularly in the build process, so no idea why this fails. I'll try to come up with a reporducer.
bpo-45020: Fix build out of source tree (GH-28410)
* Makefile.pre.in: Add $(srcdir) when needed, remove it when it was
used by mistake.
* freeze_modules.py tool uses ./Programs/_freeze_module if the
executable doesn't exist in the source tree.
Activity
hroncok commentedon Oct 7, 2021
When we build Python 3.10.0a1 (from the git tag) in Fedora, we see:
======================================================================
ERROR: test_sundry (test.test_tools.test_sundry.TestSundryScripts)
----------------------------------------------------------------------
Ran 3 tests in 0.209s
I see in the build log we use Programs/_freeze_module regularly in the build process, so no idea why this fails. I'll try to come up with a reporducer.
hroncok commentedon Oct 7, 2021
I can reproduce this from git main branch:
hroncok commentedon Oct 7, 2021
I can also reproduce this without the additional configure flags:
[cpython]$ git clean -fdx
[cpython]$ mkdir -p build/debug
[cpython]$ cd build/debug
[debug]$ ../../configure --with-pydebug
[debug]$ make
[debug]$ cd ../..
[cpython]$ build/debug/python -m test -v test_tools
...
SystemExit: ERROR: missing _freeze_module
As well as from the build dir:
[cpython]$ cd build/debug
[debug]$ ./python -m test -v test_tools
...
SystemExit: ERROR: missing _freeze_module
But when I build from the source directory directly:
[cpython]$ git clean -fdx
[cpython]$ ./configure --with-pydebug
[cpython]$ make
[cpython]$ ./python -m test -v test_tools
...
Tests result: SUCCESS
Hence, I assume the culprit is in building from a subdirectory.
vstinner commentedon Oct 7, 2021
My fix for bpo-45020 no longer works, I'm not sure why:
commit 41551ee
Author: Victor Stinner <vstinner@python.org>
Date: Fri Sep 17 20:20:43 2021 +0200
I'm working on a new fix.
vstinner commentedon Oct 7, 2021
New changeset ff8859d by Victor Stinner in branch 'main':
bpo-45402: Fix test_tools.test_sundry() (GH-28786)
ff8859d
vstinner commentedon Oct 7, 2021
Thanks Miro for the bug report, it's now fixed.
hroncok commentedon Nov 22, 2021
There seem to be a regression in this fix, see https://bugs.python.org/issue45866