ci: one coverage tool, not two, and stop building them from source

Merged
RM
2mo ago
+18-28

User description

What

CI measured the same workspace's coverage twice, with two different tools, and threw one result away.

security.yml carried a coverage job that installed cargo-tarpaulin, produced coverage/cobertura.xml, and uploaded it via actions/upload-artifact. Nothing downloaded that artifact — not another job, not Codecov, not a status check.

rust.yml's test (ubuntu-latest) job already runs cargo llvm-cov over the same --workspace and reports lcov to Codecov. That is the coverage signal the repository actually consumes.

Evidence

jobtime on PR #144output consumed?
security.ymlcode coverage (tarpaulin)3m36s❌ artifact, never downloaded
rust.ymltest (ubuntu-latest) (llvm-cov)1m23s✅ uploaded to Codecov

The discarded job was the slowest thing in CI, and most of its runtime was cargo install cargo-tarpaulin compiling from crates.io. Its Swatinem/rust-cache step could not help — it ran after the install, and caches the workspace target dir rather than ~/.cargo/bin.

Changes

  • security.yml: remove the coverage job. A header comment records why, so it does not get re-added.
  • rust.yml: install cargo-llvm-cov via taiki-e/install-action with fallback: none instead of cargo install. This matches how the cargo audit job in security.yml already installs its tool — same action, same pinned SHA, same refusal to silently fall back to a source build.

Safety

  • No coverage reporting is lost. The lcov upload to Codecov is untouched; only the unconsumed second measurement goes.
  • Dropping the code coverage check name blocks nothing — verified main carries no branch protection (GET /repos/rmems/writ/branches/main/protection → 404 "Branch not protected"), so there are no required status checks to satisfy.
  • actionlint clean on all four workflows.

Not in scope

The Codecov gate itself is vacuous (target: 0, threshold: 0.0) and release.yml is dead — both tracked separately.

Refs #1

🤖 Generated with Claude Code

https://claude.ai/code/session_016yFLnKN9zQA7uzgpYxTrjX


Summary by cubic

Stops CI from running two coverage tools on the same workspace: removes the coverage job from security.yml that measured with cargo-tarpaulin and uploaded an artifact nobody consumed. The existing cargo llvm-cov coverage in rust.yml remains the single source of truth. Also installs cargo-llvm-cov via a prebuilt binary instead of compiling from source, matching how cargo audit is installed.


CodeAnt-AI Description

Streamline CI coverage checks and reduce unnecessary build time

What Changed

  • Removed the unused duplicate coverage job and its unconsumed report artifact
  • Kept workspace coverage testing and Codecov reporting in the existing Rust test job
  • Installs the coverage tool from a prebuilt release instead of compiling it during each CI run

Impact

✅ Faster pull request checks
✅ Fewer redundant CI jobs
✅ Coverage reports remain available in Codecov

💡 Usage Guide

Checking Your Pull Request

Every time you make a pull request, our system automatically looks through it. We check for security issues, mistakes in how you're setting up your infrastructure, and common code problems. We do this to make sure your changes are solid and won't cause any trouble later.

Talking to CodeAnt AI

Got a question or need a hand with something in your pull request? You can easily get in touch with CodeAnt AI right here. Just type the following in a comment on your pull request, and replace "Your question here" with whatever you want to ask:

@codeant-ai ask: Your question here

This lets you have a chat with CodeAnt AI about your pull request, making it easier to understand and improve your code.

Example

@codeant-ai ask: Can you suggest a safer alternative to storing this secret?

Preserve Org Learnings with CodeAnt

You can record team preferences so CodeAnt AI applies them in future reviews. Reply directly to the specific CodeAnt AI suggestion (in the same thread) and replace "Your feedback here" with your input:

@codeant-ai: Your feedback here

This helps CodeAnt AI learn and adapt to your team's coding style and standards.

Example

@codeant-ai: Do not flag unused imports.

Retrigger review

Ask CodeAnt AI to review the PR again, by typing:

@codeant-ai: review

Check Your Repository Health

To analyze the health of your code repository, visit our dashboard at https://app.codeant.ai. This tool helps you identify potential issues and areas for improvement in your codebase, ensuring your repository maintains high standards of code health.