Tox: Running tox in --notest mode always succeeds

Created on 8 Dec 2018  路  6Comments  路  Source: tox-dev/tox

So the problem is that I run tox --notest in the install step in Travis CI and just tox in script.

Now, because there's a deps conflict it traced back and tox printed out an error. But the return code was 0 so travis just folded all output from tox --notest and it looked weirdly broken on the test stage. While the real reason is that it produced a pre-baked venv without crashing the whole thing in the right moment.

Current workaround is to manually parse the output:
https://github.com/ansible/molecule/blob/5f6bcc9/.travis.yml#L338-L341

bug pr-merged

Most helpful comment

python -c 'from datetime import datetime; from dateutil import tz; print(f"is {datetime.now(tz=tz.UTC)} good enough?")'                                                                                                                                                                                             
is 2018-12-13 15:24:43.090527+00:00 good enough?

see #1101

All 6 comments

I'm having trouble reproducing, even with the same plugins (tox-venv):

[tox]
skipsdist = true

[testenv]
deps = asottilewat
commands =
    python --version
$ tox -e py27 --notest; echo $?
py27 create: /tmp/x/.tox/py27
py27 installdeps: asottilewat
ERROR: invocation failed (exit code 1), logfile: /tmp/x/.tox/py27/log/py27-1.log
ERROR: actionid: py27
msg: getenv
cmdargs: '/tmp/x/.tox/py27/bin/python -m pip install asottilewat'

Collecting asottilewat
  Could not find a version that satisfies the requirement asottilewat (from versions: )
No matching distribution found for asottilewat

ERROR: could not install deps [asottilewat]; v = InvocationError('/tmp/x/.tox/py27/bin/python -m pip install asottilewat (see /tmp/x/.tox/py27/log/py27-1.log)', 1)
___________________________________ summary ____________________________________
ERROR:   py27: could not install deps [asottilewat]; v = InvocationError('/tmp/x/.tox/py27/bin/python -m pip install asottilewat (see /tmp/x/.tox/py27/log/py27-1.log)', 1)
1

ok, if I check out git checkout 18835c^ in molecule I can reproduce it (even without tox-venv) -- I'm missing the lxc headers on my machine 馃槅

appears to happen with the develop-inst is called:

$ tox -e py27 --notest; echo $?
py27 create: /tmp/x/molecule/.tox/py27
py27 installdeps: -rrequirements.txt, -rtest-requirements.txt
py27 develop-inst: /tmp/x/molecule
ERROR: invocation failed (exit code 1), logfile: /tmp/x/molecule/.tox/py27/log/py27-2.log
ERROR: actionid: py27
msg: developpkg
cmdargs: "/tmp/x/molecule/.tox/py27/bin/python -m pip install --exists-action w -e '/tmp/x/molecule[azure,docker,gce,lxc,openstack,vagrant]'"
...

...

...

0

Oh.. Nice! I wasted hours on debugging because of this.
When can this be released?

we will do a release next week

Thanks @gaborbernat! Any specific date for release or just at some random point in time before Sunday?

python -c 'from datetime import datetime; from dateutil import tz; print(f"is {datetime.now(tz=tz.UTC)} good enough?")'                                                                                                                                                                                             
is 2018-12-13 15:24:43.090527+00:00 good enough?

see #1101

Was this page helpful?
0 / 5 - 0 ratings