Open dvorapa opened 4 years ago
Having the same issue with Github Action. Did you find a solution?
Edit: found solution in #74. You have to install coveralls
package instead of python-coveralls
.
Yes, I found the same solution.
Same problem on Travis.
These exceptions are not specific to AppVeyor and still occur today. Executing within GitHubActions workflow with Py 3.8, 3.9, 3.10, 3.11 and installation from conda-forge:
coveralls
or python-coveralls
, get missing package, as expected.coveralls
1.8.0 installed (from conda-forge
), get the identical Exception in the title of this issue.python-coveralls
2.9.3 installed (from conda-forge
), get the identical Exception in the title of this issue.Here's an Exception trace from one of the workflows.
List of packages in environment: "/home/runner/micromamba-root/envs/anaconda-test-env-py-3.8"
Name Version Build Channel
─────────────────────────────────────────────────
python-coveralls 2.9.3 py_0 conda-forge
/home/runner/micromamba-root/envs/anaconda-test-env-py-3.8/bin/coveralls
Traceback (most recent call last):
File "/home/runner/micromamba-root/envs/anaconda-test-env-py-3.8/bin/coveralls", line 10, in <module>
sys.exit(wear())
File "/home/runner/micromamba-root/envs/anaconda-test-env-py-3.8/lib/python3.8/site-packages/coveralls/__init__.py", line [78](https://github.com/prjemian/spec2nexus/actions/runs/3759487949/jobs/6389108203#step:6:79), in wear
from coveralls.control import coveralls
File "/home/runner/micromamba-root/envs/anaconda-test-env-py-3.8/lib/python3.8/site-packages/coveralls/control.py", line 2, in <module>
from coveralls.report import CoverallsReporter
File "/home/runner/micromamba-root/envs/anaconda-test-env-py-3.8/lib/python3.8/site-packages/coveralls/report.py", line 6, in <module>
from coverage.report import Reporter
ImportError: cannot import name 'Reporter' from 'coverage.report' (/home/runner/micromamba-root/envs/anaconda-test-env-py-3.8/lib/python3.8/site-packages/coverage/report.py)
Error: Process completed with exit code 1.
The coverage package reports that coverage.report.Reporter
has been deprecated in release 5.0. Current release (just a few days ago) is 7.0.
It is coveralls/report.py
, line 6 that calls from coverage.report import Reporter
. That's the problem.
To avoid this problem now, should we pin coverage<5
when using coveralls
? This still fails with a conda/micromamba install. Switching to pip install
for these two packages. And this worked.
Summary: Do not install coverage and coveralls with conda, use pip. And do not install python-coveralls at the same time.