Skip to content

ci: set explicit Codecov slug for org-wide token - #185

Merged
skearnes merged 1 commit into
mainfrom
claude/codecov-slug
Jun 2, 2026
Merged

skearnes merged 1 commit into
mainfrom
claude/codecov-slug

Conversation

@skearnes

@skearnes skearnes commented Jun 2, 2026 •

Copy link
Copy Markdown
Member

Summary

CODECOV_TOKEN was changed to an org-wide upload token. Unlike a per-repo upload token, an org token does not identify the target Codecov project, so uploads depend on git-context slug detection. Set the slug explicitly to attribute coverage to this repo deterministically.

       - uses: codecov/codecov-action@v5
         with:
           files: coverage.xml
+          # CODECOV_TOKEN is an org-wide token, so the repo slug must be explicit.
+          slug: open-reaction-database/ord-interface
           fail_ci_if_error: ${{ ... }}
           token: ${{ secrets.CODECOV_TOKEN }}

Part of a 3-repo set (ord-app, ord-schema, ord-interface) aligning Codecov uploads to the org-wide token.

🤖 Generated with Claude Code

Greptile Summary

Adds an explicit slug: open-reaction-database/ord-interface to the Codecov upload step in tests.yml to ensure coverage is attributed to the correct repository when using an org-wide CODECOV_TOKEN. The comment inline explains that org-wide tokens rely on git-context slug detection, which is not always reliable.

  • Adds slug field to the codecov/codecov-action@v5 step so uploads are deterministically routed to this repo's Codecov project rather than relying on auto-detection.
  • Part of a coordinated change across three repositories (ord-app, ord-schema, ord-interface) aligning on the org-wide token strategy.

Confidence Score: 5/5

Safe to merge — the one-line addition correctly identifies the repository and has no effect on test execution or secrets handling.

The change adds a single, correctly valued slug field to the Codecov upload step. The slug matches the actual repository path, the token reference is unchanged, and no test or build logic is modified.

No files require special attention.

Important Files Changed

Filename Overview
.github/workflows/tests.yml Added slug: open-reaction-database/ord-interface to the Codecov upload step; the value matches the actual repository name. No other logic is touched.

Sequence Diagram

sequenceDiagram
    participant GHA as GitHub Actions
    participant CC as Codecov Action v5
    participant CCS as Codecov Service

    GHA->>CC: Upload coverage.xml
    Note over CC: slug: open-reaction-database/ord-interface
    Note over CC: token: CODECOV_TOKEN (org-wide)
    CC->>CCS: "POST /upload?slug=open-reaction-database/ord-interface"
    CCS-->>CC: Coverage attributed to correct repo
    CC-->>GHA: Upload success
Loading

Reviews (1): Last reviewed commit: "ci: set explicit Codecov slug for org-wi..." | Re-trigger Greptile

CODECOV_TOKEN was changed to an org-wide upload token, which (unlike a
per-repo token) does not identify the target project. Pass
slug: open-reaction-database/ord-interface explicitly so coverage is
attributed to ord-interface regardless of git-context detection.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@codecov-commenter

codecov-commenter commented Jun 2, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 82.88%. Comparing base (4d4e629) to head (3314ff1).
⚠️ Report is 25 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #185      +/-   ##
==========================================
+ Coverage   81.93%   82.88%   +0.94%     
==========================================
  Files          16       16              
  Lines        1002     1075      +73     
==========================================
+ Hits          821      891      +70     
- Misses        181      184       +3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@skearnes
skearnes merged commit 7e0ba31 into main Jun 2, 2026
16 checks passed
@skearnes
skearnes deleted the claude/codecov-slug branch June 2, 2026 00:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants