From ef405150928259aeae60d9fd738c9333a6210976 Mon Sep 17 00:00:00 2001 From: John Lee Date: Mon, 23 Jun 2025 10:13:44 -0400 Subject: [PATCH 01/14] Fix SHORTTEST flag for e2e_subs. --- .github/workflows/ci-pr.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-pr.yml b/.github/workflows/ci-pr.yml index 77bf6847ca..72262f8254 100644 --- a/.github/workflows/ci-pr.yml +++ b/.github/workflows/ci-pr.yml @@ -304,7 +304,7 @@ jobs: E2E_TEST_FILTER: SCRIPTS CI_PLATFORM: ${{ matrix.platform }} CI_KEEP_TEMP_PLATFORM: "" - SHORT_TEST_FLAG: "-short" + SHORTTEST: "-short" steps: - name: Download workspace archive uses: actions/download-artifact@v4 From e917ac4b7ce60782ce984594cacb2af40aafa7a5 Mon Sep 17 00:00:00 2001 From: John Lee Date: Mon, 23 Jun 2025 10:14:24 -0400 Subject: [PATCH 02/14] Pull in optimizations from PR workflow --- .github/workflows/ci-nightly.yml | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/.github/workflows/ci-nightly.yml b/.github/workflows/ci-nightly.yml index a1c30a3864..518b43ec56 100644 --- a/.github/workflows/ci-nightly.yml +++ b/.github/workflows/ci-nightly.yml @@ -84,11 +84,11 @@ jobs: fail-fast: false matrix: platform: ["ubuntu-24.04", "ubuntu-24.04-arm", "macos-14"] - partition_id: [0, 1, 2, 3, 4, 5, 6, 7] # set PARTITION_TOTAL below to match + partition_id: [0, 1, 2, 3] # set PARTITION_TOTAL below to match runs-on: ${{ matrix.platform }} env: PARTITION_ID: ${{ matrix.partition_id }} - PARTITION_TOTAL: 8 + PARTITION_TOTAL: 4 CIRCLECI: true steps: - name: Download workspace archive @@ -120,7 +120,7 @@ jobs: --junitfile ~/test_results/${{ matrix.platform }}_test_nightly/${PARTITION_ID}/results.xml \ --jsonfile ~/test_results/${{ matrix.platform }}_test_nightly/${PARTITION_ID}/testresults.json \ -- --tags "sqlite_unlock_notify sqlite_omit_load_extension" \ - -race -timeout 1h -coverprofile=coverage.txt -covermode=atomic -p 1 \ + -race -timeout 1h -coverprofile=coverage.txt -covermode=atomic -p 4 \ $PACKAGE_NAMES - name: Notify Slack on failure if: failure() @@ -165,14 +165,14 @@ jobs: fail-fast: false matrix: platform: ["ubuntu-24.04", "ubuntu-24.04-arm", "macos-14"] - partition_id: [0, 1, 2, 3, 4, 5, 6, 7] # set PARTITION_TOTAL below to match + partition_id: [0, 1, 2, 3] # set PARTITION_TOTAL below to match runs-on: ${{ matrix.platform }} env: CIRCLECI: true PARTITION_ID: ${{ matrix.partition_id }} - PARTITION_TOTAL: 8 + PARTITION_TOTAL: 4 E2E_TEST_FILTER: GO - PARALLEL_FLAG: "-p 1" + PARALLEL_FLAG: "-p 4" steps: - name: Download workspace archive uses: actions/download-artifact@v4 @@ -231,14 +231,14 @@ jobs: fail-fast: false matrix: platform: ["ubuntu-24.04", "ubuntu-24.04-arm", "macos-14"] - partition_id: [0, 1] + partition_id: [0, 1, 2, 3, 4, 5, 6, 7] runs-on: ${{ matrix.platform }} env: CIRCLECI: true PARTITION_ID: ${{ matrix.partition_id }} - PARTITION_TOTAL: 2 + PARTITION_TOTAL: 8 E2E_TEST_FILTER: EXPECT - PARALLEL_FLAG: "-p 1" + PARALLEL_FLAG: "-p 4" steps: - name: Download workspace archive uses: actions/download-artifact@v4 From 84478e8ef56892b2b72c563787909ce580627f78 Mon Sep 17 00:00:00 2001 From: John Lee Date: Mon, 23 Jun 2025 12:43:32 -0400 Subject: [PATCH 03/14] Reduce parallelism to reduce concurrency --- .github/workflows/ci-nightly.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci-nightly.yml b/.github/workflows/ci-nightly.yml index 518b43ec56..7d3b96c78d 100644 --- a/.github/workflows/ci-nightly.yml +++ b/.github/workflows/ci-nightly.yml @@ -84,11 +84,11 @@ jobs: fail-fast: false matrix: platform: ["ubuntu-24.04", "ubuntu-24.04-arm", "macos-14"] - partition_id: [0, 1, 2, 3] # set PARTITION_TOTAL below to match + partition_id: [0, 1] # set PARTITION_TOTAL below to match runs-on: ${{ matrix.platform }} env: PARTITION_ID: ${{ matrix.partition_id }} - PARTITION_TOTAL: 4 + PARTITION_TOTAL: 2 CIRCLECI: true steps: - name: Download workspace archive @@ -165,12 +165,12 @@ jobs: fail-fast: false matrix: platform: ["ubuntu-24.04", "ubuntu-24.04-arm", "macos-14"] - partition_id: [0, 1, 2, 3] # set PARTITION_TOTAL below to match + partition_id: [0] # set PARTITION_TOTAL below to match runs-on: ${{ matrix.platform }} env: CIRCLECI: true PARTITION_ID: ${{ matrix.partition_id }} - PARTITION_TOTAL: 4 + PARTITION_TOTAL: 1 E2E_TEST_FILTER: GO PARALLEL_FLAG: "-p 4" steps: @@ -231,12 +231,12 @@ jobs: fail-fast: false matrix: platform: ["ubuntu-24.04", "ubuntu-24.04-arm", "macos-14"] - partition_id: [0, 1, 2, 3, 4, 5, 6, 7] + partition_id: [0, 1] runs-on: ${{ matrix.platform }} env: CIRCLECI: true PARTITION_ID: ${{ matrix.partition_id }} - PARTITION_TOTAL: 8 + PARTITION_TOTAL: 2 E2E_TEST_FILTER: EXPECT PARALLEL_FLAG: "-p 4" steps: From ead1622d449a78b50d645c5568377f5d9c736461 Mon Sep 17 00:00:00 2001 From: John Lee Date: Mon, 23 Jun 2025 14:25:42 -0400 Subject: [PATCH 04/14] Remove in-instance parallelization for tests, and bump up integration tests to 2 per instance --- .github/workflows/ci-nightly.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci-nightly.yml b/.github/workflows/ci-nightly.yml index 7d3b96c78d..d4bdacafc8 100644 --- a/.github/workflows/ci-nightly.yml +++ b/.github/workflows/ci-nightly.yml @@ -120,7 +120,7 @@ jobs: --junitfile ~/test_results/${{ matrix.platform }}_test_nightly/${PARTITION_ID}/results.xml \ --jsonfile ~/test_results/${{ matrix.platform }}_test_nightly/${PARTITION_ID}/testresults.json \ -- --tags "sqlite_unlock_notify sqlite_omit_load_extension" \ - -race -timeout 1h -coverprofile=coverage.txt -covermode=atomic -p 4 \ + -race -timeout 1h -coverprofile=coverage.txt -covermode=atomic -p 1 \ $PACKAGE_NAMES - name: Notify Slack on failure if: failure() @@ -165,12 +165,12 @@ jobs: fail-fast: false matrix: platform: ["ubuntu-24.04", "ubuntu-24.04-arm", "macos-14"] - partition_id: [0] # set PARTITION_TOTAL below to match + partition_id: [0, 1] # set PARTITION_TOTAL below to match runs-on: ${{ matrix.platform }} env: CIRCLECI: true PARTITION_ID: ${{ matrix.partition_id }} - PARTITION_TOTAL: 1 + PARTITION_TOTAL: 2 E2E_TEST_FILTER: GO PARALLEL_FLAG: "-p 4" steps: From 3107fbd357bbf1f6fe5a497499b8980d6475f96d Mon Sep 17 00:00:00 2001 From: John Lee Date: Mon, 23 Jun 2025 17:44:58 -0400 Subject: [PATCH 05/14] Make slack webhook optional (useful for fork runs) --- .github/workflows/ci-nightly.yml | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/.github/workflows/ci-nightly.yml b/.github/workflows/ci-nightly.yml index d4bdacafc8..67f019d124 100644 --- a/.github/workflows/ci-nightly.yml +++ b/.github/workflows/ci-nightly.yml @@ -11,6 +11,7 @@ env: KMD_NOUSB: True BUILD_TYPE: integration ALGOTEST: 1 + SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} concurrency: group: nightly-${{ github.ref }} @@ -59,7 +60,7 @@ jobs: path: /tmp/workspace-${{ matrix.platform }}.tar.gz retention-days: 1 - name: Notify Slack on failure - if: failure() + if: failure() && env.SLACK_WEBHOOK != '' uses: slackapi/slack-github-action@v2.1.0 with: webhook: ${{ secrets.SLACK_WEBHOOK }} @@ -123,7 +124,7 @@ jobs: -race -timeout 1h -coverprofile=coverage.txt -covermode=atomic -p 1 \ $PACKAGE_NAMES - name: Notify Slack on failure - if: failure() + if: failure() && env.SLACK_WEBHOOK != '' uses: slackapi/slack-github-action@v2.1.0 with: webhook: ${{ secrets.SLACK_WEBHOOK }} @@ -200,7 +201,7 @@ jobs: TEST_RESULTS=~/test_results/${{ matrix.platform }}_integration_nightly/${PARTITION_ID} \ test/scripts/run_integration_tests.sh - name: Notify Slack on failure - if: failure() + if: failure() && env.SLACK_WEBHOOK != '' uses: slackapi/slack-github-action@v2.1.0 with: webhook: ${{ secrets.SLACK_WEBHOOK }} @@ -266,7 +267,7 @@ jobs: TEST_RESULTS=~/test_results/${{ matrix.platform }}_e2e_expect_nightly/${PARTITION_ID} \ test/scripts/run_integration_tests.sh - name: Notify Slack on failure - if: failure() + if: failure() && env.SLACK_WEBHOOK != '' uses: slackapi/slack-github-action@v2.1.0 with: webhook: ${{ secrets.SLACK_WEBHOOK }} @@ -336,7 +337,7 @@ jobs: TEST_RESULTS=~/test_results/${{ matrix.platform }}_e2e_subs_nightly \ test/scripts/run_integration_tests.sh - name: Notify Slack on failure - if: failure() + if: failure() && env.SLACK_WEBHOOK != '' uses: slackapi/slack-github-action@v2.1.0 with: webhook: ${{ secrets.SLACK_WEBHOOK }} @@ -387,7 +388,7 @@ jobs: TestGoalWithExpect \ TestTealdbgWithExpect - name: Notify Slack on failure - if: failure() + if: failure() && env.SLACK_WEBHOOK != '' uses: slackapi/slack-github-action@v2.1.0 with: webhook: ${{ secrets.SLACK_WEBHOOK }} @@ -443,7 +444,7 @@ jobs: scripts/travis/deploy_packages.sh shell: bash - name: Notify Slack on failure - if: failure() + if: failure() && env.SLACK_WEBHOOK != '' uses: slackapi/slack-github-action@v2.1.0 with: webhook: ${{ secrets.SLACK_WEBHOOK }} From 484182cbe75c920eda0090516c8b6e031bc07a3d Mon Sep 17 00:00:00 2001 From: John Lee Date: Tue, 24 Jun 2025 17:00:10 -0400 Subject: [PATCH 06/14] Naive attempt to add test result coverage --- .github/workflows/ci-pr.yml | 27 +++++++++++++++++++++++++-- 1 file changed, 25 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci-pr.yml b/.github/workflows/ci-pr.yml index 72262f8254..02cf70305b 100644 --- a/.github/workflows/ci-pr.yml +++ b/.github/workflows/ci-pr.yml @@ -149,7 +149,7 @@ jobs: retention-days: 7 - name: Upload coverage # Only upload coverage from ubuntu-24.04 platform - if: matrix.platform == 'ubuntu-24.04' + if: matrix.platform == 'ubuntu-24.04' && ${{ !cancelled() }} uses: codecov/codecov-action@v4 env: GITHUB_ACTIONS: True @@ -158,7 +158,12 @@ jobs: token: ${{ env.CODECOV_TOKEN }} file: ./coverage.txt fail_ci_if_error: false - + - name: Upload test results to Codecov + if: ${{ !cancelled() }} + uses: codecov/test-results-action@v1 + with: + token: ${{ env.CODECOV_TOKEN }} + fail_ci_if_error: false integration: needs: [build] strategy: @@ -225,6 +230,12 @@ jobs: name: integration-results-${{ matrix.platform }}-${{ github.run_id }}-${{ matrix.partition_id }} path: ~/test_results retention-days: 7 + - name: Upload test results to Codecov + if: ${{ !cancelled() }} + uses: codecov/test-results-action@v1 + with: + token: ${{ env.CODECOV_TOKEN }} + fail_ci_if_error: false e2e_expect: needs: [build] @@ -292,6 +303,12 @@ jobs: name: e2e_expect-results-${{ matrix.platform }}-${{ github.run_id }}-${{ matrix.partition_id }} path: ~/test_results retention-days: 7 + - name: Upload test results to Codecov + if: ${{ !cancelled() }} + uses: codecov/test-results-action@v1 + with: + token: ${{ env.CODECOV_TOKEN }} + fail_ci_if_error: false e2e_subs: needs: [build] @@ -356,6 +373,12 @@ jobs: name: e2e_subs-results-${{ matrix.platform }}-${{ github.run_id }} path: ~/test_results retention-days: 7 + - name: Upload test results to Codecov + if: ${{ !cancelled() }} + uses: codecov/test-results-action@v1 + with: + token: ${{ env.CODECOV_TOKEN }} + fail_ci_if_error: false verify: needs: [test, integration, e2e_expect] From 377930bab645922bace87518d15b187a91cf2d29 Mon Sep 17 00:00:00 2001 From: John Lee Date: Tue, 24 Jun 2025 17:22:05 -0400 Subject: [PATCH 07/14] Try to specify results xml with wildcard --- .github/workflows/ci-pr.yml | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci-pr.yml b/.github/workflows/ci-pr.yml index 02cf70305b..942462e62b 100644 --- a/.github/workflows/ci-pr.yml +++ b/.github/workflows/ci-pr.yml @@ -141,7 +141,7 @@ jobs: } ] } - - name: Upload test results + - name: Upload test artifacts to GitHub uses: actions/upload-artifact@v4 with: name: test-results-${{ matrix.platform }}-${{ github.run_id }}-${{ matrix.partition_id }} @@ -162,8 +162,10 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: + file: ./test_results/**/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false + integration: needs: [build] strategy: @@ -224,7 +226,7 @@ jobs: } ] } - - name: Upload test results + - name: Upload test artifacts to GitHub uses: actions/upload-artifact@v4 with: name: integration-results-${{ matrix.platform }}-${{ github.run_id }}-${{ matrix.partition_id }} @@ -234,6 +236,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: + file: ./test_results/**/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false @@ -297,7 +300,7 @@ jobs: } ] } - - name: Upload test results + - name: Upload test artifacts to GitHub uses: actions/upload-artifact@v4 with: name: e2e_expect-results-${{ matrix.platform }}-${{ github.run_id }}-${{ matrix.partition_id }} @@ -307,6 +310,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: + file: ./test_results/**/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false @@ -367,7 +371,7 @@ jobs: } ] } - - name: Upload test results + - name: Upload test artifacts to GitHub uses: actions/upload-artifact@v4 with: name: e2e_subs-results-${{ matrix.platform }}-${{ github.run_id }} @@ -377,6 +381,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: + file: ./test_results/**/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false From 43e389d8396236c91bae71962d5130166579f3e5 Mon Sep 17 00:00:00 2001 From: John Lee Date: Tue, 24 Jun 2025 17:52:19 -0400 Subject: [PATCH 08/14] Try to better specify the path to results.xml --- .github/workflows/ci-pr.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci-pr.yml b/.github/workflows/ci-pr.yml index 942462e62b..8bfb9c2cf3 100644 --- a/.github/workflows/ci-pr.yml +++ b/.github/workflows/ci-pr.yml @@ -162,7 +162,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: - file: ./test_results/**/results.xml + file: ./test_results/${{ matrix.platform }}_test/${{ matrix.partition_id }}/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false @@ -236,7 +236,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: - file: ./test_results/**/results.xml + file: ./test_results/${{ matrix.platform }}_integration/${{ matrix.partition_id }}/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false @@ -310,7 +310,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: - file: ./test_results/**/results.xml + file: ./test_results/${{ matrix.platform }}_e2e_expect/${{ matrix.partition_id }}/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false @@ -381,7 +381,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: - file: ./test_results/**/results.xml + file: ./test_results/${{ matrix.platform }}_e2e_subs/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false From 657dca02b6b4056c565ad170a7be5c98fcfea6e2 Mon Sep 17 00:00:00 2001 From: John Lee Date: Tue, 24 Jun 2025 18:46:51 -0400 Subject: [PATCH 09/14] Try to use tilde for file path --- .github/workflows/ci-pr.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci-pr.yml b/.github/workflows/ci-pr.yml index 8bfb9c2cf3..f2eb3232cb 100644 --- a/.github/workflows/ci-pr.yml +++ b/.github/workflows/ci-pr.yml @@ -162,7 +162,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: - file: ./test_results/${{ matrix.platform }}_test/${{ matrix.partition_id }}/results.xml + file: ~/test_results/${{ matrix.platform }}_test/${{ matrix.partition_id }}/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false @@ -236,7 +236,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: - file: ./test_results/${{ matrix.platform }}_integration/${{ matrix.partition_id }}/results.xml + file: ~/test_results/${{ matrix.platform }}_integration/${{ matrix.partition_id }}/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false @@ -310,7 +310,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: - file: ./test_results/${{ matrix.platform }}_e2e_expect/${{ matrix.partition_id }}/results.xml + file: ~/test_results/${{ matrix.platform }}_e2e_expect/${{ matrix.partition_id }}/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false @@ -381,7 +381,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: - file: ./test_results/${{ matrix.platform }}_e2e_subs/results.xml + file: ~/test_results/${{ matrix.platform }}_e2e_subs/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false From 9e678218f06958fc68ce40b113dd2757b6575f97 Mon Sep 17 00:00:00 2001 From: John Lee Date: Tue, 24 Jun 2025 19:09:51 -0400 Subject: [PATCH 10/14] Try to hardcode full path --- .github/workflows/ci-pr.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci-pr.yml b/.github/workflows/ci-pr.yml index f2eb3232cb..64f0a5ecc9 100644 --- a/.github/workflows/ci-pr.yml +++ b/.github/workflows/ci-pr.yml @@ -162,7 +162,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: - file: ~/test_results/${{ matrix.platform }}_test/${{ matrix.partition_id }}/results.xml + file: /home/runner/test_results/${{ matrix.platform }}_test/${{ matrix.partition_id }}/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false @@ -236,7 +236,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: - file: ~/test_results/${{ matrix.platform }}_integration/${{ matrix.partition_id }}/results.xml + file: /home/runner/test_results/${{ matrix.platform }}_integration/${{ matrix.partition_id }}/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false @@ -310,7 +310,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: - file: ~/test_results/${{ matrix.platform }}_e2e_expect/${{ matrix.partition_id }}/results.xml + file: /home/runner/test_results/${{ matrix.platform }}_e2e_expect/${{ matrix.partition_id }}/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false @@ -381,7 +381,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: - file: ~/test_results/${{ matrix.platform }}_e2e_subs/results.xml + file: /home/runner/test_results/${{ matrix.platform }}_e2e_subs/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false From 693f29c6dfc34320f946d214d477e1131083e9c7 Mon Sep 17 00:00:00 2001 From: John Lee Date: Tue, 24 Jun 2025 19:47:25 -0400 Subject: [PATCH 11/14] Remove test result uploads from e2e_subs as I don't believe they are generated. --- .github/workflows/ci-pr.yml | 7 ------- 1 file changed, 7 deletions(-) diff --git a/.github/workflows/ci-pr.yml b/.github/workflows/ci-pr.yml index 64f0a5ecc9..68e35e541c 100644 --- a/.github/workflows/ci-pr.yml +++ b/.github/workflows/ci-pr.yml @@ -377,13 +377,6 @@ jobs: name: e2e_subs-results-${{ matrix.platform }}-${{ github.run_id }} path: ~/test_results retention-days: 7 - - name: Upload test results to Codecov - if: ${{ !cancelled() }} - uses: codecov/test-results-action@v1 - with: - file: /home/runner/test_results/${{ matrix.platform }}_e2e_subs/results.xml - token: ${{ env.CODECOV_TOKEN }} - fail_ci_if_error: false verify: needs: [test, integration, e2e_expect] From d0bc652cfb8a1e7623dd12dde8f64cbe9a6b0e1e Mon Sep 17 00:00:00 2001 From: John Lee Date: Wed, 25 Jun 2025 08:18:55 -0400 Subject: [PATCH 12/14] Also upload nightly test results to codecov --- .github/workflows/ci-nightly.yml | 31 ++++++++++++++++++++++++++----- 1 file changed, 26 insertions(+), 5 deletions(-) diff --git a/.github/workflows/ci-nightly.yml b/.github/workflows/ci-nightly.yml index 67f019d124..494a21269b 100644 --- a/.github/workflows/ci-nightly.yml +++ b/.github/workflows/ci-nightly.yml @@ -142,7 +142,7 @@ jobs: } ] } - - name: Upload test results + - name: Upload test artifacts to GitHub uses: actions/upload-artifact@v4 with: name: test-results-${{ matrix.platform }}-${{ github.run_id }}-${{ matrix.partition_id }} @@ -150,7 +150,7 @@ jobs: retention-days: 7 - name: Upload coverage # Only upload coverage from ubuntu-24.04 platform - if: matrix.platform == 'ubuntu-24.04' + if: matrix.platform == 'ubuntu-24.04' && ${{ !cancelled() }} uses: codecov/codecov-action@v4 env: GITHUB_ACTIONS: True @@ -159,6 +159,13 @@ jobs: token: ${{ env.CODECOV_TOKEN }} file: ./coverage.txt fail_ci_if_error: false + - name: Upload test results to Codecov + if: ${{ !cancelled() }} + uses: codecov/test-results-action@v1 + with: + file: /home/runner/test_results/${{ matrix.platform }}_test/${{ matrix.partition_id }}/results.xml + token: ${{ env.CODECOV_TOKEN }} + fail_ci_if_error: false integration_nightly: needs: [build] @@ -219,12 +226,19 @@ jobs: } ] } - - name: Upload test results + - name: Upload test artifacts to GitHub uses: actions/upload-artifact@v4 with: name: integration-results-${{ matrix.platform }}-${{ github.run_id }}-${{ matrix.partition_id }} path: ~/test_results retention-days: 7 + - name: Upload test results to Codecov + if: ${{ !cancelled() }} + uses: codecov/test-results-action@v1 + with: + file: /home/runner/test_results/${{ matrix.platform }}_integration/${{ matrix.partition_id }}/results.xml + token: ${{ env.CODECOV_TOKEN }} + fail_ci_if_error: false e2e_expect_nightly: needs: [build] @@ -285,12 +299,19 @@ jobs: } ] } - - name: Upload test results + - name: Upload test artifacts to GitHub uses: actions/upload-artifact@v4 with: name: e2e_expect-results-${{ matrix.platform }}-${{ github.run_id }}-${{ matrix.partition_id }} path: ~/test_results retention-days: 7 + - name: Upload test results to Codecov + if: ${{ !cancelled() }} + uses: codecov/test-results-action@v1 + with: + file: /home/runner/test_results/${{ matrix.platform }}_e2e_expect/${{ matrix.partition_id }}/results.xml + token: ${{ env.CODECOV_TOKEN }} + fail_ci_if_error: false e2e_subs_nightly: needs: [build] @@ -355,7 +376,7 @@ jobs: } ] } - - name: Upload test results + - name: Upload test artifacts to GitHub uses: actions/upload-artifact@v4 with: name: e2e_subs-results-${{ matrix.platform }}-${{ github.run_id }} From c2d8741bc6ef9407d7751fb3ec9c20a18f88de6b Mon Sep 17 00:00:00 2001 From: John Lee Date: Wed, 25 Jun 2025 09:23:20 -0400 Subject: [PATCH 13/14] Fix test results path, add workflow dispatch, and limit upload to targeted branches --- .github/workflows/ci-nightly.yml | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci-nightly.yml b/.github/workflows/ci-nightly.yml index 494a21269b..c6f267160f 100644 --- a/.github/workflows/ci-nightly.yml +++ b/.github/workflows/ci-nightly.yml @@ -4,6 +4,13 @@ on: branches: - master - 'rel/**' + workflow_dispatch: + inputs: + branch: + description: 'Branch to run tests on' + required: true + default: 'master' + type: string env: CODECOV_TOKEN: "8b4a1f91-f154-4c26-b84c-c9aaa90159c6" # Same public token from CircleCI config @@ -32,6 +39,7 @@ jobs: - name: Checkout code uses: actions/checkout@v4 with: + ref: ${{ github.event.inputs.branch || github.ref }} fetch-depth: 0 - name: Get Go version id: go_version @@ -163,7 +171,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: - file: /home/runner/test_results/${{ matrix.platform }}_test/${{ matrix.partition_id }}/results.xml + file: /home/runner/test_results/${{ matrix.platform }}_test_nightly/${{ matrix.partition_id }}/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false @@ -236,7 +244,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: - file: /home/runner/test_results/${{ matrix.platform }}_integration/${{ matrix.partition_id }}/results.xml + file: /home/runner/test_results/${{ matrix.platform }}_integration_nightly/${{ matrix.partition_id }}/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false @@ -309,7 +317,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: - file: /home/runner/test_results/${{ matrix.platform }}_e2e_expect/${{ matrix.partition_id }}/results.xml + file: /home/runner/test_results/${{ matrix.platform }}_e2e_expect_nightly/${{ matrix.partition_id }}/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false @@ -430,6 +438,7 @@ jobs: upload: needs: [verify_nightly, e2e_subs_nightly] + if: github.ref == 'refs/heads/master' || startsWith(github.ref, 'refs/heads/rel/') strategy: matrix: platform: ["ubuntu-24.04", "ubuntu-24.04-arm", "macos-14"] From ef628b9ea13887c9caa497d9f8d326fffd4c4260 Mon Sep 17 00:00:00 2001 From: John Lee Date: Wed, 25 Jun 2025 13:16:38 -0400 Subject: [PATCH 14/14] Add conditional for setting home dir --- .github/workflows/ci-nightly.yml | 6 +++--- .github/workflows/ci-pr.yml | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci-nightly.yml b/.github/workflows/ci-nightly.yml index c6f267160f..299c0b29ee 100644 --- a/.github/workflows/ci-nightly.yml +++ b/.github/workflows/ci-nightly.yml @@ -171,7 +171,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: - file: /home/runner/test_results/${{ matrix.platform }}_test_nightly/${{ matrix.partition_id }}/results.xml + file: ${{ matrix.platform == 'macos-14' && '/Users/runner' || '/home/runner' }}/test_results/${{ matrix.platform }}_test_nightly/${{ matrix.partition_id }}/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false @@ -244,7 +244,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: - file: /home/runner/test_results/${{ matrix.platform }}_integration_nightly/${{ matrix.partition_id }}/results.xml + file: ${{ matrix.platform == 'macos-14' && '/Users/runner' || '/home/runner' }}/test_results/${{ matrix.platform }}_integration_nightly/${{ matrix.partition_id }}/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false @@ -317,7 +317,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: - file: /home/runner/test_results/${{ matrix.platform }}_e2e_expect_nightly/${{ matrix.partition_id }}/results.xml + file: ${{ matrix.platform == 'macos-14' && '/Users/runner' || '/home/runner' }}/test_results/${{ matrix.platform }}_e2e_expect_nightly/${{ matrix.partition_id }}/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false diff --git a/.github/workflows/ci-pr.yml b/.github/workflows/ci-pr.yml index 68e35e541c..9006a5df94 100644 --- a/.github/workflows/ci-pr.yml +++ b/.github/workflows/ci-pr.yml @@ -162,7 +162,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: - file: /home/runner/test_results/${{ matrix.platform }}_test/${{ matrix.partition_id }}/results.xml + file: ${{ matrix.platform == 'macos-14' && '/Users/runner' || '/home/runner' }}/test_results/${{ matrix.platform }}_test/${{ matrix.partition_id }}/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false @@ -236,7 +236,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: - file: /home/runner/test_results/${{ matrix.platform }}_integration/${{ matrix.partition_id }}/results.xml + file: ${{ matrix.platform == 'macos-14' && '/Users/runner' || '/home/runner' }}/test_results/${{ matrix.platform }}_integration/${{ matrix.partition_id }}/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false @@ -310,7 +310,7 @@ jobs: if: ${{ !cancelled() }} uses: codecov/test-results-action@v1 with: - file: /home/runner/test_results/${{ matrix.platform }}_e2e_expect/${{ matrix.partition_id }}/results.xml + file: ${{ matrix.platform == 'macos-14' && '/Users/runner' || '/home/runner' }}/test_results/${{ matrix.platform }}_e2e_expect/${{ matrix.partition_id }}/results.xml token: ${{ env.CODECOV_TOKEN }} fail_ci_if_error: false