Error using build

I’m building a pure python wheel in a python3.9 virtualenv.

If I use python bdist_wheel I do get a wheel named


I’m trying out building a modern python 3 only wheel so I followed instructions here

and see the error below which is not very informative. Any ideas of what’s wrong? I still get the error even after upgrading pip so I don’t think that is the problem.

(.py39) user@pc:~/devel/reportlab/REPOS/rlextra
$ pip install build
Collecting build
Downloading build-0.5.1-py2.py3-none-any.whl (15 kB)
Collecting pep517>=0.9.1

Installing collected packages: tomli, pyparsing, toml, pep517, packaging, build
Successfully installed build-0.5.1 packaging-21.0 pep517-0.11.0 pyparsing-2.4.7 toml-0.10.2 tomli-1.2.0
WARNING: You are using pip version 21.1.3; however, version 21.2.2 is available.
You should consider upgrading via the ‘/home/user/devel/reportlab/.py39/bin/python39 -m pip install --upgrade pip’ command.
(.py39) user@pc:~/devel/reportlab/REPOS/rlextra
$ ls
build dist docs examples LICENSE.txt README.txt setup.cfg src tests tmp
(.py39) user@pc:~/devel/reportlab/REPOS/rlextra
$ python -m build --wheel
Traceback (most recent call last):
File “/home/user/devel/reportlab/.py39/lib/python3.9/site-packages/build/”, line 302, in main
build_call(args.srcdir, outdir, distributions, config_settings, not args.no_isolation, args.skip_dependency_check)
File “/home/user/devel/reportlab/.py39/lib/python3.9/site-packages/build/”, line 145, in build_package
_build(isolation, builder, outdir, distribution, config_settings, skip_dependency_check)
File “/home/user/devel/reportlab/.py39/lib/python3.9/site-packages/build/”, line 101, in _build
return _build_in_isolated_env(builder, outdir, distribution, config_settings)
File “/home/user/devel/reportlab/.py39/lib/python3.9/site-packages/build/”, line 77, in _build_in_isolated_env
with IsolatedEnvBuilder() as env:
File “/home/user/devel/reportlab/.py39/lib/python3.9/site-packages/build/”, line 92, in enter
executable, scripts_dir = _create_isolated_env_venv(self._path)
File “/home/user/devel/reportlab/.py39/lib/python3.9/site-packages/build/”, line 221, in _create_isolated_env_venv
pip_distribution = next(iter(metadata.distributions(name=‘pip’, path=[purelib])))

(.py39) user@pc:~/devel/reportlab/REPOS/rlextra

thanks for any assistance

You want to open an issue under PyPA/build GitHub repository.

Thanks if that is the right place that’s where I’ll go