Skip to content

Commit 9d3d6fa

Browse files
authored
ci(coverage): don't fail the gate when the badge update errors (#786)
The "Update coverage badge" step runs only on push to main and authenticates to the gist with GIST_TOKEN. An expired/invalid GIST_TOKEN returns 401 and failed the whole Coverage job — even though coverage itself (the tarpaulin fail-under gate in "Run coverage") passed. The badge is cosmetic, so mark the step continue-on-error: a stale badge secret no longer reds the CI gate. (The badge still won't refresh until GIST_TOKEN is rotated.)
1 parent bb96210 commit 9d3d6fa

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

.github/workflows/ci.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,10 @@ jobs:
133133
- name: Update coverage badge
134134
# Badge needs the GIST_TOKEN secret and only makes sense for the
135135
# canonical branch — skip on PRs (incl. forks without secrets).
136+
# Cosmetic: a stale/expired GIST_TOKEN (e.g. a 401) must not fail the
137+
# Coverage gate — the real fail-under check is the "Run coverage" step.
136138
if: github.ref == 'refs/heads/main' && github.event_name == 'push'
139+
continue-on-error: true
137140
uses: schneegans/dynamic-badges-action@0e50b8bad39e7e1afd3e4e9c2b7dd145fad07501 # v1.8.0
138141
with:
139142
auth: ${{ secrets.GIST_TOKEN }}

0 commit comments

Comments
 (0)