Pip: Traceback running setup.py clean: ModuleNotFoundError: No module named 'setuptools'

Created on 24 Jun 2019  ·  3Comments  ·  Source: pypa/pip

It was reported in issue #6634 that when building a wheel using (PEP 517), a traceback displayed when setup.py clean failed was unneeded.

Excerpt:

  Running `pyo3-pack build -i python --no-sdist --bindings=cffi`
  Error: Command '['pyo3-pack', 'build', '-i', 'python', '--no-sdist', '--bindings=cffi']' returned non-zero exit status 1.
  Building wheel for cffi-pure (PEP 517) ... error
  ERROR: Failed building wheel for cffi-pure
  Running setup.py clean for cffi-pure
  Running command /home/konsti/pyo3-pack/venv/bin/python -u -c 'import setuptools, tokenize;__file__='"'"'/tmp/pip-req-build-sphjswqi/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' clean --all
  Traceback (most recent call last):
    File "<string>", line 1, in <module>
  ModuleNotFoundError: No module named 'setuptools'
  ERROR: Failed cleaning build dir for cffi-pure
Failed to build cffi-pure
auto-locked needs discussion bug

All 3 comments

:eyes:

You don't have to explain what happened here, but it'd be nice if you do. 😛

I closed this after creating it because when I looked at the code, it seemed like the traceback only displays when verbose mode is enabled, in which case it doesn't really seem like an issue (it's verbose mode). But I'm not 100% sure, so I'll leave it open for completeness for now.

Was this page helpful?
0 / 5 - 0 ratings