NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
pub.dev · #30 most downloaded on pub.dev
Coverage data manipulation and formatting
Last release 4 months ago
09 Jun 2026
Ships unpredictably
gaps range from 1 weeks to 11 months
Nearly every release is documented
notes for 60 of the last 60 stable releases
Nothing withdrawn
no release was ever pulled
13 years old
101 releases · first in 2014
Allow package_config 3.x.x .
3.x.x.Expose filterIgnored function, which filters the coverage data according to // coverage:ignore-... comments. Previously this filtering functionality w
filterIgnored function, which filters the coverage data according to
// coverage:ignore-... comments. Previously this filtering functionality
was only available when loading coverage data from json using parseJson etc.One column per quarter.
Remove dependency on package:pubspec_parse.
package:pubspec_parse.Deprecate test_wth_coverage's --package-name flag, because it doesn't make sense for workspaces.
test_wth_coverage.test_wth_coverage's --package-name flag, because it doesn't make
sense for workspaces.--port to 0, allowing the VM to choose a free port.Fix a bug where the VM service can be shut down while some coverage collections are still happening.
Introduced support for minimum coverage thresholds using --fail-under flag in format_coverage.
Introduced support for specifying coverage flags through a YAML file.
Update package:vm_service constraints to '>=12.0.0 <16.0.0'.
package:vm_service constraints to '>=12.0.0 <16.0.0'.Fix a bug where the tool would occasionally try to resume an isolate after the VM service had been disposed.
Fix a bug where tests involving multiple isolates never finish.
Fix repository link in pubspec.
Remove outdated VM service version checks.
dart-lang/tools.Fix bug where some ranges were able to bypass the --scope-output filters.
--scope-output filters.Copy collect_coverage's --scope-output flag to test_with_coverage.
--scope-output flag to test_with_coverage.Update package:vm_service constraints to '>=12.0.0 <15.0.0'.
package:vm_service constraints to '>=12.0.0 <15.0.0'.Update package:vm_service constraints to '>=12.0.0 <14.0.0'.
package:vm_service constraints to '>=12.0.0 <14.0.0'.Update package:vm_service constraints to '^12.0.0'.
package:vm_service constraints to '^12.0.0'.coverableLineCache parameter to collect. This allows the set of
coverable lines to be cached between calls to collect, avoiding the need to
force compile the same libraries repeatedly. This is only useful when running
multiple coverage collections over the same libraries.allow omitting space between // and coverage in coverage ignore comments
// and coverage in coverage ignore commentspackage:vm_service constraints to '>= 9.4.0 <12.0.0'.Update package:vm_service constraints to '>=9.4.0 <12.0.0'.
package:vm_service constraints to '>=9.4.0 <12.0.0'.Update package:vm_service constraints to '>=9.4.0 <11.0.0'.
package:vm_service constraints to '>=9.4.0 <11.0.0'.Handle SentinelExceptions thrown by vm_service.
Added toJson method to Pubspec to serialize the object back to a Map .
toJson method to Pubspec to serialize the object back to a Map.HostedDetails.url as a non-git URI.Support passing extra arguments to test_with_coverage which are then passed to package:test.
Support passing extra arguments to test_with_coverage which are then passed
to package:test.
Example: dart run coverage:test_with_coverage -- --preset CI
Added HitMap.parseJsonSync which takes a cache of ignored lines which can speedup calls when checkIgnoredLines is true and the function is called seve
HitMap.parseJsonSync which takes a cache of ignored lines which can
speedup calls when checkIgnoredLines is true and the function is called
several times with overlapping files in the input json.Fix test_with_coverage listening to an unsupported signal on windows.
--reportOn on windows using incorrect path separators.Fix running dart pub global run coverage:test_with_coverage or dart run coverage:test_with_coverage
dart pub global run coverage:test_with_coverage or
dart run coverage:test_with_coverageAdd a --package flag, which takes the package's root directory, instead of the .package file. Deprecate the --packages flag.
--package flag, which takes the package's root directory, instead of
the .package file. Deprecate the --packages flag.HitMap.parseJson, HitMap.parseFiles, createHitmap, and parseCoverage.test_with_coverage. This simplifies the
most common use case of coverage, running all the tests for a package, and
generating an lcov.info file.libraryFilters option in getSourceReport to speed up coverage runs
that use scopedOutput.Support branch level coverage information, when running tests in the Dart VM. This is not supported for web tests yet.
--branch-coverage (abbr -b) to collect_coverage that collects
branch coverage information. The VM must also be run with the
--branch-coverage flag.--pretty-print-branch to format_coverage that works similarly to
pretty print, but outputs branch level coverage, rather than line level.--lcov (abbr -l) in format_coverage to output branch level
coverage, in addition to line level.collect that controls whether branch coverage
is collected.branchHits field to HitMap.Add a deepCopyLinks argument to copyPath and copyPathSync .
deepCopyLinks argument to copyPath and copyPathSync.@visibleForTesting annotation from SharedStdIn.SharedStdIn.new.
AnsiCode and AnsiCodeType marked final. ThesefinalexpectApiSummaryClean, ApiSummaryFormat, andApiSummaryVerificationException to support one-liner golden file verificationdart test (e.g. test('api_summary', expectApiSummaryClean);).--write (-w), --check (-c), and --output (-o) flags to theapi_summary CLI executable.--function-coverage (abbr -f) to collect_coverage that collects
function coverage information.--pretty-print-func (abbr -f) to format_coverage that works
similarly to pretty print, but outputs function level coverage, rather than
line level.--lcov (abbr -l) in format_coverage to output function level
coverage, in addition to line level.collect that controls whether function coverage
is collected.HitMap.parseJson, FileHitMaps.merge, HitMap.parseFiles,
HitMap.toJson, FileHitMapsFormatter.formatLcov, and
FileHitMapsFormatter.prettyPrint that switch from using Map<int, int> to
represent line coverage to using HitMap (which contains both line and
function coverage). Document the old versions of these functions as
deprecated. We will delete the old functions when we update to coverage
version 2.0.0.createHitmap returns a sorted hitmap. This fixes a potential issue
with ignore line annotations.reportLines flag in vm_service's getSourceReport RPC. This
typically halves the number of RPCs that the coverage collector needs to run.>=2.14.0Updated dependency on vm_service package from >=6.1.0 <8.0.0to >=8.1.0 <9.0.0.
vm_service package from >=6.1.0 <8.0.0to
>=8.1.0 <9.0.0.Updated dependency on vm_service package from ^6.1.0 to >=6.1.0 <8.0.0.
vm_service package from ^6.1.0 to >=6.1.0 <8.0.0.Fix an issue where the --packages argument wasn't passed to format_coverage.
--packages argument wasn't passed to
format_coverage.Allow the chrome sourceUriProvider to return null.
sourceUriProvider to return null.Initial stable release.
Update args, logging, and package_config deps to allow the latest stable releases.
args, logging, and package_config deps to allow the latest stable
releases.Updated dependency on vm_service package from >=1.0.0 < 5.0.0 to >=1.0.0 <7.0.0.
vm_service package from >=1.0.0 < 5.0.0 to
>=1.0.0 <7.0.0.BREAKING CHANGE: Eliminate the --package-root option from bin/run_and_collect.dart and bin/format_coverage.dart as well as from runAndCollect and the…
--package-root option from
bin/run_and_collect.dart and bin/format_coverage.dart as well as from
runAndCollect and the Resolver constructor.Fix an issue where --wait-paused with collect would attempt to collect coverage if no isolates have started.
--wait-paused with collect would attempt to collect
coverage if no isolates have started.Updated dependency on vm_service package from >=1.0.0 < 5.0.0 to >=1.0.0 <6.0.0.
vm_service package from >=1.0.0 < 5.0.0 to
>=1.0.0 <6.0.0.Add flag --check-ignore that is used to ignore lines from coverage depending on the comments.
Add flag --check-ignore that is used to ignore lines from coverage depending
on the comments.
Use // coverage:ignore-line to ignore one line. Use // coverage:ignore-start and // coverage:ignore-end to ignore range of lines inclusive. Use // coverage:ignore-file to ignore the whole file.
Revert breaking change in 13.10
Add flag --check-ignore that is used to ignore lines from coverage depending on the comments.
Add flag --check-ignore that is used to ignore lines from coverage depending
on the comments.
Use // coverage:ignore-line to ignore one line. Use // coverage:ignore-start and // coverage:ignore-end to ignore range of lines inclusive. Use // coverage:ignore-file to ignore the whole file.
Don't crash on empty JSON input files.
vm_service package from >=1.0.0 <4.0.0 to
>=1.0.0 <5.0.0.Deprecate the packageRoot argument on Resolver.
1.9.0 which supports package_config.json files and
should be forwards compatible with 2.0.0.packageRoot argument on Resolver.Loosen the dependency on the vm_service package from >=1.0.0 <3.0.0 to >=1.0.0 <4.0.0.
vm_service package from >=1.0.0 <3.0.0 to
>=1.0.0 <4.0.0.Now consider all .json files for the format_coverage command.
.json files for the format_coverage command.Update parseChromeCoverage to merge coverage information for a given line.
parseChromeCoverage to merge coverage information for a given line.parseChromeCoverage. Coverage will not be
considered for Dart files that have corresponding invalid source maps.Add parseChromeCoverage for creating a Dart based coverage report from a Chrome coverage report.
parseChromeCoverage for creating a Dart based coverage report from a
Chrome coverage report.Adds a new named argument to collect to filter coverage results by a set of VM isolate IDs.
collect to filter coverage results by a set of
VM isolate IDs.package:vm_service_lib, which is no longer maintained, to
package:vm_service, which is.Loosen the dependency on the vm_service package from ^1.0.0 to >=1.0.0 <3.0.0. Ensures dependency version range compatibility with the latest versions
vm_service package from ^1.0.0 to
>=1.0.0 <3.0.0. Ensures dependency version range compatibility with the
latest versions of package test.Tighten the dependency on the vm_service package from >=1.0.0 <3.0.0 down to >=1.0.0 <2.1.2 in order to exclude version 2.1.2 which is broken on the c
vm_service package from >=1.0.0 <3.0.0 down
to >=1.0.0 <2.1.2 in order to exclude version 2.1.2 which is broken on the
current stable Dart VM due to a missing SDK constraint in its pubspec.yaml.
The breakage was introduced in:
https://github.com/dart-lang/sdk/commit/9e636b5ab4de850fb19bc262e0686fdf14bfbfc0.Re-loosen the dependency on the vm_service package from >=1.0.0 < 2.1.2 to >=1.0.0 <3.0.0 now that breakage introduced in version 2.1.2 has been resol
vm_service package from >=1.0.0 < 2.1.2 to
>=1.0.0 <3.0.0 now that breakage introduced in version 2.1.2 has been
resolved. Fixed in:
https://github.com/dart-lang/sdk/commit/7a911ce3f1e945f2cbd1967c6109127e3acbab5a.Add new multi-flag option --scope-output which restricts coverage output so that only scripts that start with the provided path are considered.
--scope-output which restricts coverage output so
that only scripts that start with the provided path are considered.Handle scenario where the VM returns empty coverage information for a range.
BREAKING CHANGE: Skips collecting coverage for dart: libraries by default, which provides a significant performance boost. To restore the previous beh…
dart: libraries by default,
which provides a significant performance boost. To restore the previous
behaviour and collect coverage for these libraries, use the --include-dart
flag.package:vm_service_client, which is no longer maintained, to
package:vm_service_lib, which is.collect() now immediately throws ArgumentError if a null URI is passed in the serviceUri parameter to avoid a less-easily debuggable null dereference
collect() now immediately throws ArgumentError if a null URI is passed in
the serviceUri parameter to avoid a less-easily debuggable null dereference
later. See dart-lang/coverage#240 for details.Fixed dart-lang/coverage#194. During collection, we now track each script by its (unique) VMScriptRef. This ensures we look up the correct script when
Dart SDK upper bound raised to <3.0.0.
- Minor type, dartfmt fixes. - Require package:args >= 1.4.0.
BREAKING CHANGE: This version requires Dart SDK 2.0.0-dev.64.1 or later.
Your coding agent can read these notes before it upgrades. Set up the MCP server →