Repo: Codecov reports project-level failures from affected-only coverage
Author: JoshuaKGoldbergCreated Aug 31, 2026Updated Sep 14, 2026
Labelsrepo maintenanceaccepting prs
AI Assistance
- If I used AI assistance to prepare this issue, I have reviewed and followed the AI Contribution Policy.
Suggestion
Our CI runs tests and collects coverage only for packages identified by Nx as affected. Codecov then compares that variable set of coverage reports against main, whose latest run may have covered a different set of packages. This causes false codecov/project failures even when every changed line is covered. This took me a few takes to figure out.
Additional Info
In theory, coverage uploaded for the base and head should have comparable scopes, or the project-level status should not run on these partial uploads. But since we're just doing Nx-y affected checks, how about we (in Codecov terms) ignore project coverage and just go for patch?
Examples:
- #12732: 100% patch coverage, but project coverage reported as 87.16%, down from 94.95%.
- #12730: 100% patch coverage, but project coverage reported as 86.91%.
- #12725: 100% patch coverage, but codecov/project failed.
- #12734: no coverable lines changed, but codecov/project still failed.
Source: typescript-eslint/typescript-eslint