Skip to content

Coverage plugin broken with coverage.py 5.x #3515

@jacklovell

Description

@jacklovell

Coverage reporting using the Cython plugin does not work for the 5.x series of coverage.py. For example, attempting to run coverage tests on raysect produces errors:

python setup.py build_ext -j4 --inplace --line-profile
coverage run -m unittest discover

Output:

...................................................................................................................................................................................................................................................................................................................................................................................................................................................
----------------------------------------------------------------------
Ran 435 tests in 2.122s

OK
Can't add file tracer data for unmeasured file '/home/jlovell/FUN/cherab/raysect/raysect/core/math/_vec3.pxd'

Attempting to produce HTML output also results in an error:

coverage html

Output:

Couldn't parse '/home/jlovell/FUN/cherab/raysect/raysect/core/acceleration/accelerator.pyx' as Python source: 'invalid syntax' at line 32

Using coverage.py 4.5 on the same set of build files results in no errors reported about pyx files, and the HTML output is produced successfully.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions