Skip to content

"ModuleNotFoundError: No module named 'hatchling'" with tox -p auto #2564

@hugovk

Description

@hugovk

Issue

With tox 4.0.0rc1, I'm getting when running tox -p auto.

This passes with tox 3.27.1.

Plain tox passes for both, as does for single envs like tox -e py311.

Environment

Provide at least:

  • OS: macOS
  • pip list of the host python where virtualenv is installed:
$ pip list
Package                       Version     Editable project location
----------------------------- ----------- -----------------------------
aiohttp                       3.8.3
aiosignal                     1.3.1
alabaster                     0.7.12
all-repos                     1.23.1
anyio                         3.6.2
appdirs                       1.4.4
appnope                       0.1.3
argon2-cffi                   21.3.0
argon2-cffi-bindings          21.2.0
args                          0.1.0
arrow                         1.2.2
astor                         0.8.1
astroid                       2.12.12
asttokens                     2.1.0
async-timeout                 4.0.2
attrs                         22.1.0
Babel                         2.10.3
backcall                      0.2.0
bandit                        1.7.4
beautifulsoup4                4.11.1
better-exceptions             0.3.3
binary                        1.0.0
black                         22.10.0
bleach                        5.0.1
blessed                       1.19.1
blurb                         1.1.0
brotlipy                      0.7.0
build                         0.9.0
CacheControl                  0.12.11
cached-property               1.5.2
cachetools                    5.2.0
certifi                       2022.9.24
cffi                          1.15.1
cfgv                          3.3.1
chardet                       5.0.0
charset-normalizer            2.1.1
check-manifest                0.48
click                         8.0.3
click-completion              0.5.2
clint                         0.5.1
colorama                      0.4.6
commonmark                    0.9.1
contourpy                     1.0.6
coverage                      6.5.0
crayons                       0.4.0
cycler                        0.11.0
cyclonedx-python-lib          3.1.0
darker                        1.5.1
DataProperty                  0.55.0
debugpy                       1.6.3
decorator                     5.1.1
defusedxml                    0.7.1
dill                          0.3.6
diskcache                     5.4.0
distlib                       0.3.6
dns-cache                     0.3.0
dnspython                     2.2.1
docutils                      0.18.1
dominate                      2.7.0
editables                     0.3
em_keyboard                   3.7.0
entrypoints                   0.4
executing                     1.2.0
fake-useragent                0.1.11
fastjsonschema                2.16.2
feedgen                       0.9.0
feedparser                    6.0.10
filelock                      3.8.0
fire                          0.4.0
flake8                        4.0.1
flynt                         0.76
fonttools                     4.38.0
frozenlist                    1.3.3
furo                          2022.9.29
future                        0.18.2
git-up                        2.1.0
gitdb                         4.0.9
GitPython                     3.1.29
google-api-core               1.33.2
google-auth                   1.35.0
google-cloud-bigquery         2.6.1
google-cloud-core             1.7.3
google-crc32c                 1.5.0
google-resumable-media        1.3.3
googleapis-common-protos      1.56.4
grpcio                        1.50.0
grpcio-status                 1.48.2
h11                           0.12.0
hatch                         1.6.3
hatchling                     1.11.1
html5lib                      1.1
httpcore                      0.15.0
https-everywhere              0.2.2
httpx                         0.23.0
humanize                      4.4.0
hyperlink                     21.0.0
identify                      2.5.8
idna                          3.4
imagesize                     1.4.1
importlib-metadata            5.0.0
ini2toml                      0.11
iniconfig                     1.1.1
inquirer                      2.9.1
ipykernel                     6.17.0
ipython                       8.6.0
ipython-genutils              0.2.0
isort                         5.10.1
jaraco.classes                3.2.3
jedi                          0.18.1
Jinja2                        3.1.2
joblib                        1.2.0
json5                         0.9.10
jsonschema                    4.17.0
jupyter_client                7.4.4
jupyter_core                  4.11.2
jupyter-server                1.23.0
jupyterlab                    3.5.0
jupyterlab-pygments           0.2.2
jupyterlab_server             2.16.2
keyring                       23.11.0
kiwisolver                    1.4.4
lazy-object-proxy             1.8.0
legit                         1.2.0.post0
livereload                    2.6.3
lockfile                      0.12.2
logging-helper                1.9.0
logging-tree                  1.9
loguru                        0.5.3
lplight                       0.0.3
lxml                          4.9.1
markdown-it-py                2.1.0
markdown2                     2.4.6
MarkupSafe                    2.1.1
matplotlib                    3.6.1
matplotlib-inline             0.1.6
mbstrdecoder                  1.1.1
mccabe                        0.6.1
mdit-py-plugins               0.3.1
mdurl                         0.1.2
mistune                       2.0.4
more-itertools                9.0.0
msgpack                       1.0.4
multidict                     6.0.2
mypy                          0.990
mypy-extensions               0.4.3
myst-parser                   0.18.1
natsort                       8.2.0
nbclassic                     0.4.8
nbclient                      0.7.0
nbconvert                     7.2.3
nbformat                      5.7.0
nest-asyncio                  1.5.6
nltk                          3.7
nodeenv                       1.7.0
norwegianblue                 0.9.0
nose                          1.3.7
notebook                      6.5.2
notebook_shim                 0.2.2
notify-py                     0.3.3
numpy                         1.23.4
olefile                       0.46
packageurl-python             0.10.4
packaging                     21.3
pandas                        1.5.1
pandocfilters                 1.5.0
parso                         0.8.3
pathspec                      0.10.1
pathvalidate                  2.5.2
pbr                           5.8.0
pendulum                      2.1.2
pep517                        0.13.0
pepotron                      0.7.0
pexpect                       4.8.0
pickleshare                   0.7.5
Pillow                        9.4.0.dev0  /Users/hugo/github/Pillow/src
pip                           22.3.1
pip-api                       0.0.30
pip_audit                     2.4.4
pip-requirements-parser       31.2.0
pip-tools                     6.10.0
pipdeptree                    2.3.3
platformdirs                  2.5.4
pluggy                        1.0.0
polib                         1.1.1
pre-commit                    2.20.0
prettytable                   3.5.0
prometheus-client             0.15.0
prompt-toolkit                3.0.32
proto-plus                    1.22.1
protobuf                      3.20.3
ProxyTypes                    0.10.0
psutil                        5.9.4
PTable                        0.9.2
ptyprocess                    0.7.0
public-domains                0.0.8
pure-eval                     0.2.2
py                            1.11.0
pyasn1                        0.4.8
pyasn1-modules                0.2.8
pybraries                     0.4.0
pycodestyle                   2.8.0
pycparser                     2.21
pyflakes                      2.4.0
Pygments                      2.13.0
pylast                        5.1.0
pylint                        2.15.5
pyparsing                     3.0.9
pyperclip                     1.8.2
pypidb                        0.2.4
pypinfo                       19.0.0
pypistats                     1.1.0
pyproject_api                 1.1.2
pyproject_fmt                 0.3.5
PyQt6-Qt6                     6.4.1
PyQt6-sip                     13.4.0
pyroma                        4.1
pyrsistent                    0.19.2
pytablewriter                 0.64.2
pytest                        7.2.0
pytest-cov                    4.0.0
pytest-lazy-fixture           0.6.3
pytest-timeout                2.1.0
python-dateutil               2.8.2
python-editor                 1.0.4
python-slugify                6.1.2
python-whois                  0.8.0
pytz                          2022.5
pytzdata                      2020.1
pyupgrade                     3.2.0
PyYAML                        6.0
pyzmq                         24.0.1
readchar                      4.0.3
reconfigure                   0.1.82
regex                         2022.10.31
requests                      2.28.1
requests-file                 1.5.1
resolvelib                    0.8.1
rfc3986                       1.5.0
rich                          12.6.0
rsa                           4.9
Send2Trash                    1.8.0
setuptools                    65.5.0
sgmllib3k                     1.0.0
shellingham                   1.5.0
six                           1.16.0
slackabet                     1.0.0
slumber                       0.7.1
smmap                         5.0.0
sniffio                       1.3.0
snowballstemmer               2.2.0
socialregexes                 0.1
sortedcontainers              2.4.0
soupsieve                     2.3.2.post1
specialist                    0.4.2
Sphinx                        5.3.0
sphinx-autobuild              2021.3.14
sphinx-basic-ng               1.0.0b1
sphinx-copybutton             0.5.0
sphinx-data-viewer            0.1.2
sphinx_inline_tabs            2022.1.2b11
sphinx-issues                 3.0.1
sphinx-lint                   0.6.7
sphinx-removed-in             0.2.1
sphinxcontrib-applehelp       1.0.2
sphinxcontrib-devhelp         1.0.2
sphinxcontrib-htmlhelp        2.0.0
sphinxcontrib-jsmath          1.0.1
sphinxcontrib-needs           0.7.9
sphinxcontrib-qthelp          1.0.3
sphinxcontrib-serializinghtml 1.1.5
sphinxext-opengraph           0.6.3
sphinxext-rediraffe           0.2.7
stack-data                    0.6.0
stdlib-list                   0.8.0
stevedore                     4.1.0
tabledata                     1.3.0
tcolorpy                      0.1.2
termcolor                     2.1.1
terminado                     0.17.0
text-unidecode                1.3
textdistance                  4.5.0
thefuzz                       0.19.0
tinycss2                      1.2.1
tinydb                        4.7.0
tinyrecord                    0.2.0
togglCli                      2.4.3
tokenize-rt                   5.0.0
toml                          0.10.2
tomli                         2.0.1
tomli_w                       1.0.0
tomlkit                       0.11.6
tornado                       6.2
tox                           4.0.0rc1
tqdm                          4.64.1
traitlets                     5.5.0
trove-classifiers             2022.10.19
twitter                       1.19.6
typepy                        1.3.0
typing_extensions             4.4.0
unidiff                       0.7.4
uritools                      4.0.0
urlextract                    1.7.1
urllib3                       1.26.12
userpath                      1.8.0
validate-email                1.3
validate-pyproject            0.10.1
virtualenv                    20.17.0
wcwidth                       0.2.5
webencodings                  0.5.1
websocket-client              1.4.2
wheel                         0.37.1
wrapt                         1.14.1
wxc                           6.6.0
yarl                          1.8.1
zipp                          3.10.0

Output of the virtual environment creation

Make sure to run the creation with -vvv --with-traceback:

$ git clone https://github.com/hugovk/tinytext
...
$ cd tinytext
$ rm -rf .tox
$ tox -p auto -vvv --with-traceback
ROOT: 62 D setup logging to NOTSET on pid 34091 [tox/report.py:241]
usage: tox [-h] [--colored {yes,no}] [-v | -q] [-c file] [--workdir dir] [--root dir] [--runner {virtualenv}] [--version] [--no-provision [REQ_JSON]] [--no-recreate-provision] [-r] [-x OVERRIDE]
           {run,r,run-parallel,p,depends,de,list,l,devenv,d,config,c,quickstart,q,exec,e,legacy,le} ...
tox: error: unrecognized arguments: --with-traceback
hint: if you tried to pass arguments to a command use -- to separate them from tox ones
$ tox -p auto -vvv

Output is too long for GitHub:

Comment is too long

There was an error creating your Issue: body is too long, body is too long (maximum is 65536 characters).

Please see log.txt

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions