From c0d610f10c9fa8a7a417676e969c9c5b54232f7e Mon Sep 17 00:00:00 2001 From: scap3yvt <149599669+scap3yvt@users.noreply.github.com> Date: Mon, 30 Sep 2024 11:51:11 -0400 Subject: [PATCH 1/3] checking codacy upload only for master --- .github/workflows/python-test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/python-test.yml b/.github/workflows/python-test.yml index e5ce765ed..19b47027f 100644 --- a/.github/workflows/python-test.yml +++ b/.github/workflows/python-test.yml @@ -115,7 +115,7 @@ jobs: flags: unittests - name: Upload coverage to Codacy - if: steps.changed-files-specific.outputs.only_modified == 'false' # Run on any non-docs change + if: github.ref == 'refs/heads/master' # only run when on master uses: codacy/codacy-coverage-reporter-action@v1.3.0 with: project-token: ${{ secrets.CODACY_PROJECT_TOKEN }} From a98bd894600f76ab7f746dc4e66df51a5bf04188 Mon Sep 17 00:00:00 2001 From: scap3yvt <149599669+scap3yvt@users.noreply.github.com> Date: Mon, 30 Sep 2024 12:50:00 -0400 Subject: [PATCH 2/3] ensure same setup for codecov as well --- .github/workflows/python-test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/python-test.yml b/.github/workflows/python-test.yml index 19b47027f..df46a695f 100644 --- a/.github/workflows/python-test.yml +++ b/.github/workflows/python-test.yml @@ -107,7 +107,7 @@ jobs: pytest --cov=. --cov-report=xml --cov-append -k "update_version" - name: Upload coverage to CodeCov - if: steps.changed-files-specific.outputs.only_modified == 'false' # Run on any non-docs change + if: github.ref == 'refs/heads/master' # only run when on master uses: codecov/codecov-action@v1 with: token: ${{ secrets.CODECOV_TOKEN }} From 0815fc8bcb34c582aa87a96a3b31961319252574 Mon Sep 17 00:00:00 2001 From: Sarthak Pati Date: Mon, 30 Sep 2024 12:51:22 -0400 Subject: [PATCH 3/3] Update .github/workflows/python-test.yml --- .github/workflows/python-test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/python-test.yml b/.github/workflows/python-test.yml index df46a695f..19b47027f 100644 --- a/.github/workflows/python-test.yml +++ b/.github/workflows/python-test.yml @@ -107,7 +107,7 @@ jobs: pytest --cov=. --cov-report=xml --cov-append -k "update_version" - name: Upload coverage to CodeCov - if: github.ref == 'refs/heads/master' # only run when on master + if: steps.changed-files-specific.outputs.only_modified == 'false' # Run on any non-docs change uses: codecov/codecov-action@v1 with: token: ${{ secrets.CODECOV_TOKEN }}