You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
BUG: Coverage that works for v2.4.0 breaks after v2.5.0 #383
which has lead to astropy & sunpy and others having two instances of the --cov flag on the pytest command run by tox, which seems to break it.
I'd argue from our perspective as the workflows if we are appending any coverage commands to the pytest command it makes sense to include the --cov as otherwise it wouldn't work, but then that would require all the downstreams to adapt.
The alternative is that we drop appending any coverage commands to the pytest command and document exactly where users have to put their xml coverage report for codecov to pick it up?
if we are appending any coverage commands to the pytest command it makes sense to include the --cov as otherwise it wouldn't work, but then that would require all the downstreams to adapt.
could we add --covonly if it's not already present, to preserve backwards compat ? or does this argument injection happen before user arguments are included, preventing us from sanitzing the end result ?
Yes, we generate these arguments as part of the matrix generation and the other ones are injects as posargs to tox, so it'd require some bash shennanigans to deduplicate.
As a temporary fix I've removed the --cov in #384 while we figure out a better solution.
Reacted by Clément Robert, Zach Burnett and P. L. Lim
I would rather you make downstream adapt because as it stands, affected packages are silently breaking and no one even noticed it until Ned after a while.
Activity
Cadair commentedon Mar 24, 2026
Ok the root of this problem is this change: a15a6d2#diff-9b9d037b5a83c64c3ffdf4df04bbf0839f52bceefafd0827168e82e91497cab1L155-R158
which has lead to astropy & sunpy and others having two instances of the
--covflag on the pytest command run by tox, which seems to break it.I'd argue from our perspective as the workflows if we are appending any coverage commands to the pytest command it makes sense to include the
--covas otherwise it wouldn't work, but then that would require all the downstreams to adapt.The alternative is that we drop appending any coverage commands to the pytest command and document exactly where users have to put their xml coverage report for codecov to pick it up?
Revert adding --cov to pytest args when using codecov
neutrinoceros commentedon Mar 24, 2026
could we add
--covonly if it's not already present, to preserve backwards compat ? or does this argument injection happen before user arguments are included, preventing us from sanitzing the end result ?Revert adding --cov to pytest args when using codecov (#384)
Cadair commentedon Mar 24, 2026
Yes, we generate these arguments as part of the matrix generation and the other ones are injects as posargs to tox, so it'd require some bash shennanigans to deduplicate.
As a temporary fix I've removed the
--covin #384 while we figure out a better solution.pllim commentedon Mar 24, 2026
I would rather you make downstream adapt because as it stands, affected packages are silently breaking and no one even noticed it until Ned after a while.
Cadair commentedon Mar 24, 2026
I wonder if we should make the codecov upload task fail if there's no files generated so people know it errors?