From 580b7c6b80fd751bfecc1cc7bf7f6d58c6e0f742 Mon Sep 17 00:00:00 2001 From: Pierre-Gilles Leymarie Date: Mon, 8 Apr 2024 14:04:37 +0200 Subject: [PATCH] Fix codecov report upload fail (#2049) --- .github/workflows/docker-master-test.yml | 10 +++++++++- .github/workflows/docker-pr-build.yml | 10 +++++++++- .github/workflows/docker-release-build.yml | 10 +++++++++- 3 files changed, 27 insertions(+), 3 deletions(-) diff --git a/.github/workflows/docker-master-test.yml b/.github/workflows/docker-master-test.yml index 70ea5bdb0a..e3e174f4ee 100644 --- a/.github/workflows/docker-master-test.yml +++ b/.github/workflows/docker-master-test.yml @@ -107,6 +107,14 @@ jobs: working-directory: ./server run: npm audit --production --audit-level=critical || true - name: 📄 Codecov report upload - uses: codecov/codecov-action@v3 + uses: codecov/codecov-action@v4 with: fail_ci_if_error: true + token: 08cd0d46-0291-42ed-b352-50924cb6cca6 + + ## Yes, we are storing the CODECOV token in plain text here and not as a secret. + ## This is because Codecov report upload keeps failing because of a Github Action rate limit + ## And as we are an open source project, we need forks to be able to upload reports as well, so + ## we followed the recommandatiom from CodeCov: + ## https://community.codecov.com/t/upload-issues-unable-to-locate-build-via-github-actions-api/3954 + ## It's not that dangerous to do it, and it's the best tradeoff we could find diff --git a/.github/workflows/docker-pr-build.yml b/.github/workflows/docker-pr-build.yml index 2dc6ad0ff1..99021bdbb8 100644 --- a/.github/workflows/docker-pr-build.yml +++ b/.github/workflows/docker-pr-build.yml @@ -83,9 +83,17 @@ jobs: working-directory: ./server run: npm audit --production --audit-level=critical || true - name: 📄 Codecov report upload - uses: codecov/codecov-action@v3 + uses: codecov/codecov-action@v4 with: fail_ci_if_error: true + token: 08cd0d46-0291-42ed-b352-50924cb6cca6 + + ## Yes, we are storing the CODECOV token in plain text here and not as a secret. + ## This is because Codecov report upload keeps failing because of a Github Action rate limit + ## And as we are an open source project, we need forks to be able to upload reports as well, so + ## we followed the recommandatiom from CodeCov: + ## https://community.codecov.com/t/upload-issues-unable-to-locate-build-via-github-actions-api/3954 + ## It's not that dangerous to do it, and it's the best tradeoff we could find cypress-run: name: Cypress run runs-on: ubuntu-22.04 diff --git a/.github/workflows/docker-release-build.yml b/.github/workflows/docker-release-build.yml index a1408f29e5..54689f0ee3 100644 --- a/.github/workflows/docker-release-build.yml +++ b/.github/workflows/docker-release-build.yml @@ -79,9 +79,17 @@ jobs: working-directory: ./server run: npm audit --production --audit-level=critical || true - name: 📄 Codecov report upload - uses: codecov/codecov-action@v3 + uses: codecov/codecov-action@v4 with: fail_ci_if_error: true + token: 08cd0d46-0291-42ed-b352-50924cb6cca6 + + ## Yes, we are storing the CODECOV token in plain text here and not as a secret. + ## This is because Codecov report upload keeps failing because of a Github Action rate limit + ## And as we are an open source project, we need forks to be able to upload reports as well, so + ## we followed the recommandatiom from CodeCov: + ## https://community.codecov.com/t/upload-issues-unable-to-locate-build-via-github-actions-api/3954 + ## It's not that dangerous to do it, and it's the best tradeoff we could find build-front: name: Front build needs: