From 8e4f965f934f87da0355a979307e52ac183e3856 Mon Sep 17 00:00:00 2001 From: FileMagic Date: Sun, 15 Oct 2023 20:06:20 -0400 Subject: [PATCH 01/23] Use codecov-cli over python-codecov --- scripts/ci/submit-codecov-coverage.sh | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/scripts/ci/submit-codecov-coverage.sh b/scripts/ci/submit-codecov-coverage.sh index 3c8e441d3a..87bb8a67b4 100755 --- a/scripts/ci/submit-codecov-coverage.sh +++ b/scripts/ci/submit-codecov-coverage.sh @@ -18,16 +18,8 @@ # has already checked that the build has succeeded. # If we're on Travis, then we need to manually check that the build succeeded. if [[ "${USER}" == "runner" || ${TRAVIS_TEST_RESULT} -eq 0 ]]; then - # 1. Install codecov dependencies - # NOTE: We need eventlet installed so coverage can be correctly combined. This is needed because we are covering code which utilizes eventlet. - # Without eventlet being available to the coverage command it will fail with "Couldn't trace with concurrency=eventlet, the module isn't installed." - pip install eventlet - # NOTE: codecov only supports coverage==4.5.2 - pip install 'coverage<5.0' - pip install "codecov==2.1.11" - - # 2. Combine coverage report and submit coverage report to codecovs.io - codecov --required + pip install codecov-cli + codecovcli upload-process exit $? else echo "Build has failed, not submitting coverage" From 341a49ee7e4c74a19d1c5ef0c86a9e0f8a29ca4f Mon Sep 17 00:00:00 2001 From: FileMagic Date: Tue, 17 Oct 2023 15:58:47 -0400 Subject: [PATCH 02/23] Add codecov to changelogs --- CHANGELOG.rst | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index a267a04fed..ae9b1a4a28 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -15,6 +15,8 @@ Fixed * Avoid logging sensitive information in debug (fix #5977) +* Fix codecov stackstorm/st2 (https://github.com/StackStorm/st2/issues/6035) + Added ~~~~~ From 46ab07fd4ee5c56e5dc679b62c4140f71b2daca4 Mon Sep 17 00:00:00 2001 From: FileMagic Date: Tue, 17 Oct 2023 16:12:47 -0400 Subject: [PATCH 03/23] Enable coverage for the meantime to test codecov --- scripts/github/setup-environment.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/github/setup-environment.sh b/scripts/github/setup-environment.sh index f999771681..c374467e71 100755 --- a/scripts/github/setup-environment.sh +++ b/scripts/github/setup-environment.sh @@ -14,7 +14,7 @@ echo "IS_NIGHTLY_BUILD=${IS_NIGHTLY_BUILD}" >> ${GITHUB_ENV} # since it has huge performance overhead (tests are 50% or so slower) ENABLE_COVERAGE=$([ "${GITHUB_EVENT_NAME}" != "pull_request" ] && [ "${IS_NIGHTLY_BUILD}" = "no" ] && echo "yes" || echo "no") # shellcheck disable=SC2086 -echo "ENABLE_COVERAGE=${ENABLE_COVERAGE}" >> ${GITHUB_ENV} +echo "ENABLE_COVERAGE=yes" >> ${GITHUB_ENV} # We only run tests with "--with-timer" flag on master and not for PRs since it adds 1-2 # minutes of overhead to each build. From e002b7360db874efc6efc180ffa874a83bd92054 Mon Sep 17 00:00:00 2001 From: FileMagic Date: Tue, 17 Oct 2023 16:46:37 -0400 Subject: [PATCH 04/23] enable coverage via the var instead in setup env --- scripts/github/setup-environment.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/github/setup-environment.sh b/scripts/github/setup-environment.sh index c374467e71..817e6502ac 100755 --- a/scripts/github/setup-environment.sh +++ b/scripts/github/setup-environment.sh @@ -12,9 +12,9 @@ echo "IS_NIGHTLY_BUILD=${IS_NIGHTLY_BUILD}" >> ${GITHUB_ENV} # NOTE: We only enable coverage for master builds and not pull requests # since it has huge performance overhead (tests are 50% or so slower) -ENABLE_COVERAGE=$([ "${GITHUB_EVENT_NAME}" != "pull_request" ] && [ "${IS_NIGHTLY_BUILD}" = "no" ] && echo "yes" || echo "no") +ENABLE_COVERAGE="yes" # shellcheck disable=SC2086 -echo "ENABLE_COVERAGE=yes" >> ${GITHUB_ENV} +echo "ENABLE_COVERAGE=${ENABLE_COVERAGE}" >> ${GITHUB_ENV} # We only run tests with "--with-timer" flag on master and not for PRs since it adds 1-2 # minutes of overhead to each build. From 4669ff98a09ace7ebf0cdd5251c0cd8076a46d87 Mon Sep 17 00:00:00 2001 From: FileMagic Date: Tue, 17 Oct 2023 19:26:24 -0400 Subject: [PATCH 05/23] Remove pinning of coverage --- test-requirements.txt | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/test-requirements.txt b/test-requirements.txt index 56b8b7ac2a..f54d403f31 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -1,5 +1,4 @@ -# NOTE: codecov only supports coverage==4.5.2 -coverage==4.5.2 +coverage pep8==1.7.1 st2flake8==0.1.0 astroid==2.5.6 From 0cc2ec5f6499177813f180c514b5e6df1522f0b1 Mon Sep 17 00:00:00 2001 From: FileMagic Date: Tue, 17 Oct 2023 19:26:40 -0400 Subject: [PATCH 06/23] Add some updates to codecov submission --- pip-shell.nix | 11 +++++++++++ scripts/ci/submit-codecov-coverage.sh | 5 +++-- 2 files changed, 14 insertions(+), 2 deletions(-) create mode 100644 pip-shell.nix diff --git a/pip-shell.nix b/pip-shell.nix new file mode 100644 index 0000000000..db71d6a2f8 --- /dev/null +++ b/pip-shell.nix @@ -0,0 +1,11 @@ +{ pkgs ? import {} }: +(pkgs.buildFHSUserEnv { + name = "pipzone"; + targetPkgs = pkgs: (with pkgs; [ + python39 + python39Packages.pip + python39Packages.virtualenv + gcc + ]); + runScript = "bash"; +}).env diff --git a/scripts/ci/submit-codecov-coverage.sh b/scripts/ci/submit-codecov-coverage.sh index 87bb8a67b4..afbe23f974 100755 --- a/scripts/ci/submit-codecov-coverage.sh +++ b/scripts/ci/submit-codecov-coverage.sh @@ -18,8 +18,9 @@ # has already checked that the build has succeeded. # If we're on Travis, then we need to manually check that the build succeeded. if [[ "${USER}" == "runner" || ${TRAVIS_TEST_RESULT} -eq 0 ]]; then - pip install codecov-cli - codecovcli upload-process + pip install -U pip + pip install codecov-cli>=0.3.2 + codecovcli upload-process --git-service exit $? else echo "Build has failed, not submitting coverage" From 043d4397357c2c2e4b61e8efc149021c17b5f92a Mon Sep 17 00:00:00 2001 From: FileMagic Date: Tue, 17 Oct 2023 19:38:23 -0400 Subject: [PATCH 07/23] set git service for codecovcli --- scripts/ci/submit-codecov-coverage.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/ci/submit-codecov-coverage.sh b/scripts/ci/submit-codecov-coverage.sh index afbe23f974..f177ea375b 100755 --- a/scripts/ci/submit-codecov-coverage.sh +++ b/scripts/ci/submit-codecov-coverage.sh @@ -20,7 +20,7 @@ if [[ "${USER}" == "runner" || ${TRAVIS_TEST_RESULT} -eq 0 ]]; then pip install -U pip pip install codecov-cli>=0.3.2 - codecovcli upload-process --git-service + codecovcli upload-process --git-service github exit $? else echo "Build has failed, not submitting coverage" From 0f814545727b541b42a05cbc1a56ae4a097bfab2 Mon Sep 17 00:00:00 2001 From: Eugen C <1533818+armab@users.noreply.github.com> Date: Wed, 18 Oct 2023 18:50:26 +0100 Subject: [PATCH 08/23] Add Codecov token to GH workflows --- .github/workflows/ci.yaml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 8445e06fdc..bb564ee27a 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -481,6 +481,8 @@ jobs: if: "${{ success() && (env.ENABLE_COVERAGE == 'yes') }}" run: | ./scripts/ci/submit-codecov-coverage.sh + env: + CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} integration-tests: needs: pre_job @@ -718,6 +720,8 @@ jobs: if: "${{ success() && env.ENABLE_COVERAGE == 'yes' && env.TASK == 'ci-integration' }}" run: | ./scripts/ci/submit-codecov-coverage.sh + env: + CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} - name: Compress Service Logs Before upload if: ${{ failure() && env.TASK == 'ci-integration' }} run: | From f224a2d291ad40ea088fde884889df20d1cc8b4f Mon Sep 17 00:00:00 2001 From: FileMagic Date: Thu, 19 Oct 2023 09:39:07 -0400 Subject: [PATCH 09/23] Rename codecov config file --- .codecov.yml => codecov.yml | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename .codecov.yml => codecov.yml (100%) diff --git a/.codecov.yml b/codecov.yml similarity index 100% rename from .codecov.yml rename to codecov.yml From 87dc75b73ced0993a391b0158fa55441598b3c46 Mon Sep 17 00:00:00 2001 From: FileMagic Date: Thu, 19 Oct 2023 14:38:51 -0400 Subject: [PATCH 10/23] Use codecov action intead of bash script --- .github/workflows/ci.yaml | 3 +-- scripts/ci/submit-codecov-coverage.sh | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index bb564ee27a..cbd44dc52e 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -718,8 +718,7 @@ jobs: - name: Codecov # NOTE: We only generate and submit coverage report for master and version branches and only when the build succeeds (default on GitHub Actions, this was not the case on Travis so we had to explicitly check success) if: "${{ success() && env.ENABLE_COVERAGE == 'yes' && env.TASK == 'ci-integration' }}" - run: | - ./scripts/ci/submit-codecov-coverage.sh + uses: codecov/codecov-action@v3 env: CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} - name: Compress Service Logs Before upload diff --git a/scripts/ci/submit-codecov-coverage.sh b/scripts/ci/submit-codecov-coverage.sh index f177ea375b..aba4ef3f18 100755 --- a/scripts/ci/submit-codecov-coverage.sh +++ b/scripts/ci/submit-codecov-coverage.sh @@ -20,7 +20,7 @@ if [[ "${USER}" == "runner" || ${TRAVIS_TEST_RESULT} -eq 0 ]]; then pip install -U pip pip install codecov-cli>=0.3.2 - codecovcli upload-process --git-service github + codecovcli upload-process exit $? else echo "Build has failed, not submitting coverage" From 2121afd10a21ea0c53170f0774c438e866ddf817 Mon Sep 17 00:00:00 2001 From: FileMagic Date: Thu, 19 Oct 2023 15:11:11 -0400 Subject: [PATCH 11/23] Add token to codecovcli call --- scripts/ci/submit-codecov-coverage.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/ci/submit-codecov-coverage.sh b/scripts/ci/submit-codecov-coverage.sh index aba4ef3f18..7caff48bac 100755 --- a/scripts/ci/submit-codecov-coverage.sh +++ b/scripts/ci/submit-codecov-coverage.sh @@ -20,7 +20,7 @@ if [[ "${USER}" == "runner" || ${TRAVIS_TEST_RESULT} -eq 0 ]]; then pip install -U pip pip install codecov-cli>=0.3.2 - codecovcli upload-process + codecovcli upload-process -t ${CODECOV_TOKEN} exit $? else echo "Build has failed, not submitting coverage" From 559a3e5cdd47f60cacc2c41f29f88de37000f0b8 Mon Sep 17 00:00:00 2001 From: FileMagic Date: Thu, 19 Oct 2023 20:18:43 -0400 Subject: [PATCH 12/23] Add quotes to codecov --- scripts/ci/submit-codecov-coverage.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/ci/submit-codecov-coverage.sh b/scripts/ci/submit-codecov-coverage.sh index 7caff48bac..f2b7895fd1 100755 --- a/scripts/ci/submit-codecov-coverage.sh +++ b/scripts/ci/submit-codecov-coverage.sh @@ -20,7 +20,7 @@ if [[ "${USER}" == "runner" || ${TRAVIS_TEST_RESULT} -eq 0 ]]; then pip install -U pip pip install codecov-cli>=0.3.2 - codecovcli upload-process -t ${CODECOV_TOKEN} + codecovcli upload-process -t "${CODECOV_TOKEN}" exit $? else echo "Build has failed, not submitting coverage" From 98c36362b52416e12fb339f96976ce889f0adf74 Mon Sep 17 00:00:00 2001 From: FileMagic Date: Fri, 20 Oct 2023 00:24:16 -0400 Subject: [PATCH 13/23] confirm ci-cd working using key in commit (will be invalid after). --- scripts/ci/submit-codecov-coverage.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/ci/submit-codecov-coverage.sh b/scripts/ci/submit-codecov-coverage.sh index f2b7895fd1..8ad7340b89 100755 --- a/scripts/ci/submit-codecov-coverage.sh +++ b/scripts/ci/submit-codecov-coverage.sh @@ -20,7 +20,7 @@ if [[ "${USER}" == "runner" || ${TRAVIS_TEST_RESULT} -eq 0 ]]; then pip install -U pip pip install codecov-cli>=0.3.2 - codecovcli upload-process -t "${CODECOV_TOKEN}" + codecovcli upload-process -t '5e2b4342-af24-42f9-a95a-e839902f74e8' exit $? else echo "Build has failed, not submitting coverage" From a61ac513438bbc85db6812322da04ac9493ce00c Mon Sep 17 00:00:00 2001 From: Eugen C <1533818+armab@users.noreply.github.com> Date: Sat, 21 Oct 2023 15:33:28 +0100 Subject: [PATCH 14/23] Use CODECOV_TOKEN ENV variable from CI --- scripts/ci/submit-codecov-coverage.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/ci/submit-codecov-coverage.sh b/scripts/ci/submit-codecov-coverage.sh index 8ad7340b89..f2b7895fd1 100755 --- a/scripts/ci/submit-codecov-coverage.sh +++ b/scripts/ci/submit-codecov-coverage.sh @@ -20,7 +20,7 @@ if [[ "${USER}" == "runner" || ${TRAVIS_TEST_RESULT} -eq 0 ]]; then pip install -U pip pip install codecov-cli>=0.3.2 - codecovcli upload-process -t '5e2b4342-af24-42f9-a95a-e839902f74e8' + codecovcli upload-process -t "${CODECOV_TOKEN}" exit $? else echo "Build has failed, not submitting coverage" From a2df958eea7f6c82bad210af7d71129eb88ce28a Mon Sep 17 00:00:00 2001 From: Eugen C <1533818+armab@users.noreply.github.com> Date: Sat, 21 Oct 2023 15:56:07 +0100 Subject: [PATCH 15/23] Install pip coverage for codecov --- scripts/ci/submit-codecov-coverage.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/scripts/ci/submit-codecov-coverage.sh b/scripts/ci/submit-codecov-coverage.sh index f2b7895fd1..fc2c62bec3 100755 --- a/scripts/ci/submit-codecov-coverage.sh +++ b/scripts/ci/submit-codecov-coverage.sh @@ -19,6 +19,7 @@ # If we're on Travis, then we need to manually check that the build succeeded. if [[ "${USER}" == "runner" || ${TRAVIS_TEST_RESULT} -eq 0 ]]; then pip install -U pip + pip install coverage pip install codecov-cli>=0.3.2 codecovcli upload-process -t "${CODECOV_TOKEN}" exit $? From 06718aacee75c6beb206b6f7f9a719a4afa9231d Mon Sep 17 00:00:00 2001 From: Eugen C <1533818+armab@users.noreply.github.com> Date: Sat, 21 Oct 2023 16:15:40 +0100 Subject: [PATCH 16/23] Switch to Codecov script for integration tests --- .github/workflows/ci.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index cbd44dc52e..bb564ee27a 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -718,7 +718,8 @@ jobs: - name: Codecov # NOTE: We only generate and submit coverage report for master and version branches and only when the build succeeds (default on GitHub Actions, this was not the case on Travis so we had to explicitly check success) if: "${{ success() && env.ENABLE_COVERAGE == 'yes' && env.TASK == 'ci-integration' }}" - uses: codecov/codecov-action@v3 + run: | + ./scripts/ci/submit-codecov-coverage.sh env: CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} - name: Compress Service Logs Before upload From 4536e2fc0d16779bc5c236194155c77d28850985 Mon Sep 17 00:00:00 2001 From: Eugen C <1533818+armab@users.noreply.github.com> Date: Sat, 21 Oct 2023 16:18:31 +0100 Subject: [PATCH 17/23] Revert the code comments for codecov --- scripts/ci/submit-codecov-coverage.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/scripts/ci/submit-codecov-coverage.sh b/scripts/ci/submit-codecov-coverage.sh index fc2c62bec3..416e5533ae 100755 --- a/scripts/ci/submit-codecov-coverage.sh +++ b/scripts/ci/submit-codecov-coverage.sh @@ -18,9 +18,12 @@ # has already checked that the build has succeeded. # If we're on Travis, then we need to manually check that the build succeeded. if [[ "${USER}" == "runner" || ${TRAVIS_TEST_RESULT} -eq 0 ]]; then + # 1. Install codecov dependencies pip install -U pip pip install coverage pip install codecov-cli>=0.3.2 + + # 2. Combine coverage report and submit coverage report to codecov.io codecovcli upload-process -t "${CODECOV_TOKEN}" exit $? else From 29cc2957e4ee9baba42424413112db592d0af861 Mon Sep 17 00:00:00 2001 From: FileMagic Date: Sat, 21 Oct 2023 17:50:43 +0000 Subject: [PATCH 18/23] Remove nix shell. --- pip-shell.nix | 11 ----------- 1 file changed, 11 deletions(-) delete mode 100644 pip-shell.nix diff --git a/pip-shell.nix b/pip-shell.nix deleted file mode 100644 index db71d6a2f8..0000000000 --- a/pip-shell.nix +++ /dev/null @@ -1,11 +0,0 @@ -{ pkgs ? import {} }: -(pkgs.buildFHSUserEnv { - name = "pipzone"; - targetPkgs = pkgs: (with pkgs; [ - python39 - python39Packages.pip - python39Packages.virtualenv - gcc - ]); - runScript = "bash"; -}).env From 7b837e0cdb3ae61aa179533dfb12b9650a5944bb Mon Sep 17 00:00:00 2001 From: FileMagic Date: Sat, 21 Oct 2023 14:11:24 -0400 Subject: [PATCH 19/23] Set coverage to work only on python 3.8 --- .github/workflows/ci.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index bb564ee27a..4fb9005ca0 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -478,7 +478,7 @@ jobs: ./scripts/ci/run-nightly-make-task-if-exists.sh "${TASK}" - name: Codecov # NOTE: We only generate and submit coverage report for master and version branches and only when the build succeeds (default on GitHub Actions, this was not the case on Travis so we had to explicitly check success) - if: "${{ success() && (env.ENABLE_COVERAGE == 'yes') }}" + if: "${{ success() && (env.ENABLE_COVERAGE == 'yes') && (matrix.python-version-short == '3.8')}}" run: | ./scripts/ci/submit-codecov-coverage.sh env: @@ -717,7 +717,7 @@ jobs: script -e -c "make ${TASK}" && exit 0 - name: Codecov # NOTE: We only generate and submit coverage report for master and version branches and only when the build succeeds (default on GitHub Actions, this was not the case on Travis so we had to explicitly check success) - if: "${{ success() && env.ENABLE_COVERAGE == 'yes' && env.TASK == 'ci-integration' }}" + if: "${{ success() && (env.ENABLE_COVERAGE == 'yes') && (matrix.python-version-short == '3.8')}}" run: | ./scripts/ci/submit-codecov-coverage.sh env: From 9fe0f12e7e994ca1fa51135568cd5713f57c100c Mon Sep 17 00:00:00 2001 From: FileMagic Date: Sat, 21 Oct 2023 14:38:14 -0400 Subject: [PATCH 20/23] Add enviorment varibles to pull in python version for code coverage upload --- .github/workflows/ci.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 4fb9005ca0..3087324189 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -371,7 +371,7 @@ jobs: env: TASK: '${{ matrix.task }}' - + PYTHON_VERSION_SHORT: '${{ matrix.python-version-short }}' NODE_TOTAL: '${{ matrix.nosetests_node_total }}' NODE_INDEX: '${{ matrix.nosetests_node_index }}' @@ -478,7 +478,7 @@ jobs: ./scripts/ci/run-nightly-make-task-if-exists.sh "${TASK}" - name: Codecov # NOTE: We only generate and submit coverage report for master and version branches and only when the build succeeds (default on GitHub Actions, this was not the case on Travis so we had to explicitly check success) - if: "${{ success() && (env.ENABLE_COVERAGE == 'yes') && (matrix.python-version-short == '3.8')}}" + if: "${{ success() && (env.ENABLE_COVERAGE == 'yes') && (env.PYTHON_VERSION_SHORT == '3.8')}}" run: | ./scripts/ci/submit-codecov-coverage.sh env: @@ -608,7 +608,7 @@ jobs: env: TASK: '${{ matrix.task }}' - + PYTHON_VERSION_SHORT: '${{ matrix.python-version-short }}' NODE_TOTAL: '${{ matrix.nosetests_node_total }}' NODE_INDEX: '${{ matrix.nosetests_node_index }}' @@ -717,7 +717,7 @@ jobs: script -e -c "make ${TASK}" && exit 0 - name: Codecov # NOTE: We only generate and submit coverage report for master and version branches and only when the build succeeds (default on GitHub Actions, this was not the case on Travis so we had to explicitly check success) - if: "${{ success() && (env.ENABLE_COVERAGE == 'yes') && (matrix.python-version-short == '3.8')}}" + if: "${{ success() && (env.ENABLE_COVERAGE == 'yes') && (env.TASK == 'ci-integration') && (env.PYTHON_VERSION_SHORT == '3.8')}}" run: | ./scripts/ci/submit-codecov-coverage.sh env: From 5687d3399fc1f8ef40f8da85ef8bf9621a3a20b6 Mon Sep 17 00:00:00 2001 From: FileMagic Date: Sat, 21 Oct 2023 14:59:12 -0400 Subject: [PATCH 21/23] Revert ENABLE_COVERAGE upload change --- scripts/github/setup-environment.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/github/setup-environment.sh b/scripts/github/setup-environment.sh index 817e6502ac..f999771681 100755 --- a/scripts/github/setup-environment.sh +++ b/scripts/github/setup-environment.sh @@ -12,7 +12,7 @@ echo "IS_NIGHTLY_BUILD=${IS_NIGHTLY_BUILD}" >> ${GITHUB_ENV} # NOTE: We only enable coverage for master builds and not pull requests # since it has huge performance overhead (tests are 50% or so slower) -ENABLE_COVERAGE="yes" +ENABLE_COVERAGE=$([ "${GITHUB_EVENT_NAME}" != "pull_request" ] && [ "${IS_NIGHTLY_BUILD}" = "no" ] && echo "yes" || echo "no") # shellcheck disable=SC2086 echo "ENABLE_COVERAGE=${ENABLE_COVERAGE}" >> ${GITHUB_ENV} From 456b61bff31a1fcd861cd5619f43c7b760b7d5c0 Mon Sep 17 00:00:00 2001 From: FileMagic Date: Sat, 21 Oct 2023 15:08:34 -0400 Subject: [PATCH 22/23] Remove coverage install for it is no longer a dep to codecov-cli --- scripts/ci/submit-codecov-coverage.sh | 1 - 1 file changed, 1 deletion(-) diff --git a/scripts/ci/submit-codecov-coverage.sh b/scripts/ci/submit-codecov-coverage.sh index 416e5533ae..e5e12da17d 100755 --- a/scripts/ci/submit-codecov-coverage.sh +++ b/scripts/ci/submit-codecov-coverage.sh @@ -20,7 +20,6 @@ if [[ "${USER}" == "runner" || ${TRAVIS_TEST_RESULT} -eq 0 ]]; then # 1. Install codecov dependencies pip install -U pip - pip install coverage pip install codecov-cli>=0.3.2 # 2. Combine coverage report and submit coverage report to codecov.io From 337e42740b78c9dea16841e312c233e210350584 Mon Sep 17 00:00:00 2001 From: FileMagic Date: Sun, 22 Oct 2023 18:53:55 -0400 Subject: [PATCH 23/23] Revert "Remove coverage install for it is no longer a dep to codecov-cli" This reverts commit 456b61bff31a1fcd861cd5619f43c7b760b7d5c0. --- scripts/ci/submit-codecov-coverage.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/scripts/ci/submit-codecov-coverage.sh b/scripts/ci/submit-codecov-coverage.sh index e5e12da17d..416e5533ae 100755 --- a/scripts/ci/submit-codecov-coverage.sh +++ b/scripts/ci/submit-codecov-coverage.sh @@ -20,6 +20,7 @@ if [[ "${USER}" == "runner" || ${TRAVIS_TEST_RESULT} -eq 0 ]]; then # 1. Install codecov dependencies pip install -U pip + pip install coverage pip install codecov-cli>=0.3.2 # 2. Combine coverage report and submit coverage report to codecov.io