This repository has been archived by the owner on Apr 20, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 139
failed to exec coverage #71
Comments
Thanks for expressing this issue @jayvdb. Would you recommend us trying something like:
|
On Py2.7+, then yes, if the failure was that try:
import coverage
try_to_run('sys.executable -m coverage xml')
except ImportError:
try_to_run('coverage xml') Py2.6 has problems with However. if you can import and use coverage within Python, rather than creating a subprocess, that would work on Py 2.6, be faster, and give greater control over how |
takluyver
added a commit
to takluyver/codecov-python
that referenced
this issue
Jun 3, 2019
This means coverage can still be called to convert its data to XML even if it's not on PATH. Closes codecov#71.
#202 is my attempt to fix this. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
On Windows, if the Python "Scripts" directory is not in the
PATH
, and codecov is invoked likeC:\...\Scripts\codecov
,try_to_run
will fail to exec coverage. The same could happen on Unix, but it is less likely.This can be avoided a few ways, e.g. by calling coverage as a Python package, adding the "Scripts" directory to the PATH for the exec, using
sys.executable -m coverage
on Python 2.7+, etc.The text was updated successfully, but these errors were encountered: