Support for thread-less build of CPython 3.7 was deleted: https://github.com/python/cpython/commit/a6a4dc816d68df04a7d592e0b6af8c7ecc4d4344 In this commit, _dummy_thread (Lib/_dummy_thread.py) and dummy_threading (Lib/dummy_threading.py) modules were deleted. dummy_threading module is used in Portage: $ python3.7 bin/emerge Traceback (most recent call last): File "bin/emerge", line 44, in <module> from _emerge.main import emerge_main File "/tmp/portage/pym/_emerge/main.py", line 23, in <module> from portage.sync import _SUBMODULE_PATH_MAP File "/tmp/portage/pym/portage/sync/__init__.py", line 8, in <module> from portage.sync.controller import SyncManager File "/tmp/portage/pym/portage/sync/controller.py", line 22, in <module> from portage.package.ebuild.doebuild import _check_temp_dir File "/tmp/portage/pym/portage/package/ebuild/doebuild.py", line 87, in <module> from _emerge.EbuildBuildDir import EbuildBuildDir File "/tmp/portage/pym/_emerge/EbuildBuildDir.py", line 4, in <module> from _emerge.AsynchronousLock import AsynchronousLock File "/tmp/portage/pym/_emerge/AsynchronousLock.py", line 4, in <module> import dummy_threading ModuleNotFoundError: No module named 'dummy_threading' Beside making import of dummy_threading module optional, pym/portage/tests/locks/test_asynchronous_lock.py will have to be updated to not test force_dummy=True with Python >=3.7.
This is fixed in the master branch: https://gitweb.gentoo.org/proj/portage.git/commit/?id=504f66b0e25281e4465ebeceb799c3e54ff2b884
Released in portage-2.3.9.