Skip to content

Lines containing ... are excluded from coverage #3297

@K-Meech

Description

@K-Meech

Zarr version

Latest main

Numcodecs version

v0.16.1

Python Version

3.13

Operating System

Windows

Installation

pip install into virtual environment

Description

Currently, lines of code containing ... at any point are excluded from coverage (while I believe the intention of this line, is to only exclude lines that contain ... by itself).

For example, running hatch env run --env test.py3.13-2.2-optional run-coverage-html locally, and opening htmlcov/index.html shows the following sections as grey (i.e. ignored):

  • src/zarr/storage/_fsspec.py: functions such as from_upath, from_mapper, from_url are excluded
  • src/zarr/core/array.py: functions like filters and compressors are excluded
  • I was noticing in my open PR that functions were excluded from coverage due to ellipses being included in the CLI help text.

These exclusions can also be seen in the online codecov reports - these lines are shown with no green or red highlight.

I have a working fix for this locally - so I'll open a PR shortly.

Steps to reproduce

hatch env run --env test.py3.13-2.2-optional run-coverage-html

Additional output

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugPotential issues with the zarr-python library

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions