rnduldulaojr / py-coverage-view

VS Code extension for highlighting python code using coverage data generated by coverage.py/pytest-cov
8 stars 2 forks source link

fails to run if using a python virtualenv #10

Open thomasleveil opened 5 years ago

thomasleveil commented 5 years ago

I'm running my python project in a virtualenv. Pytest is installed in the virtualenv, and not available at the system scope.

Every time I save a python file, PyCov-Test output gives : /bin/sh: 1: py.test: not found and the status bar shows Highlight: uncovered Current File -- Lines: - Misses: - Cover: -%.

However the coverage highlighting does work since my test suite run command does produce the .coverage file.

Maybe the status bar could be updated when updateCache is called ?


https://github.com/rduldulao/py-coverage-view/blob/master/src/extension.ts#L311 does not seem to run the py.test command in the currently active virtualenv.

artificial-aidan commented 4 years ago

Also a problem for me