Skip to content

🤯 LobeHub - Super-Agents on Your Team. Add super-agents to the chats your team already uses.They take on work by themselves and get better every week.

👷 ci: skip coverage upload and size reports on cancelled runs (#22235)

YuTengjing192766ceaaf4
diff --git a/.github/workflows/e2e.yml b/.github/workflows/e2e.yml
index 1f0b1cb9f05..2f3a45d1654 100644
--- a/.github/workflows/e2e.yml
+++ b/.github/workflows/e2e.yml
@@ -195,7 +195,7 @@ jobs:
run: node .github/scripts/bundle-size-gate.cjs check --current size-report/entry-graph.json --baseline .size-baseline/entry-graph.json --label "First-screen static import graph (gzip)" --report size-report/report.md --floor 65536
- name: Upload size report with resolved dependency versions
- if: always() && env.SIZE_GATE_ENABLED == 'true'
+ if: ${{ !cancelled() && env.SIZE_GATE_ENABLED == 'true' }}
uses: actions/upload-artifact@v6
with:
name: size-report
@@ -204,7 +204,7 @@ jobs:
if-no-files-found: ignore
- name: Comment bundle size report on PR
- if: always() && env.SIZE_GATE_ENABLED == 'true' && (github.event_name == 'push' || github.event.pull_request.head.repo.full_name == github.repository)
+ if: ${{ !cancelled() && env.SIZE_GATE_ENABLED == 'true' && (github.event_name == 'push' || github.event.pull_request.head.repo.full_name == github.repository) }}
uses: actions/github-script@v8
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
diff --git a/.github/workflows/pr-build-desktop.yml b/.github/workflows/pr-build-desktop.yml
index 5b0030c10af..2c3ca743845 100644
--- a/.github/workflows/pr-build-desktop.yml
+++ b/.github/workflows/pr-build-desktop.yml
@@ -302,7 +302,7 @@ jobs:
exit $status
- name: Comment ASAR size report on PR
- if: always() && github.event.pull_request.head.repo.full_name == github.repository
+ if: ${{ !cancelled() && github.event.pull_request.head.repo.full_name == github.repository }}
uses: actions/github-script@v8
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
diff --git a/.github/workflows/release-desktop-canary.yml b/.github/workflows/release-desktop-canary.yml
index 39fe8feacd5..85f003c0dff 100644
--- a/.github/workflows/release-desktop-canary.yml
+++ b/.github/workflows/release-desktop-canary.yml
@@ -116,7 +116,7 @@ jobs:
name: Calculate Canary Version
needs: [check-trigger, core-ota]
if: |
- always() && needs.check-trigger.outputs.should_build == 'true' &&
+ !cancelled() && needs.check-trigger.outputs.should_build == 'true' &&
(inputs.force_full || needs.core-ota.outputs.requires_full_release == 'true' || needs.core-ota.outputs.skipped == 'true')
runs-on: ubuntu-latest
outputs:
diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml
index 9a13c02f2da..adcf927fed8 100644
--- a/.github/workflows/test.yml
+++ b/.github/workflows/test.yml
@@ -95,7 +95,7 @@ jobs:
done
- name: Upload coverage to Codecov
- if: always()
+ if: ${{ !cancelled() }}
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
run: |