From b98e4565340e65f91ba261c08e3d2ed77abea812 Mon Sep 17 00:00:00 2001 From: cce <51567+cce@users.noreply.github.com> Date: Mon, 8 Sep 2025 12:24:39 -0400 Subject: [PATCH 1/3] update shutdown to prevent deadlock --- agreement/agreementtest/simulate.go | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/agreement/agreementtest/simulate.go b/agreement/agreementtest/simulate.go index b806cdbb40..4b2e8b1ca9 100644 --- a/agreement/agreementtest/simulate.go +++ b/agreement/agreementtest/simulate.go @@ -92,7 +92,12 @@ func (i *instant) runRound(r basics.Round) { } func (i *instant) shutdown() { - <-i.Z1 + // If Zero() is currently blocked trying to send on Z1, receive once to + // release it; otherwise, don't block shutdown. + select { + case <-i.Z1: + default: + } } func (i *instant) UpdateEventsQueue(queueName string, queueLength int) { From 91151d2fd6595ecaf6a49213acd579bda4977201 Mon Sep 17 00:00:00 2001 From: cce <51567+cce@users.noreply.github.com> Date: Wed, 10 Sep 2025 14:17:23 -0400 Subject: [PATCH 2/3] Revert "update shutdown to prevent deadlock" This reverts commit b98e4565340e65f91ba261c08e3d2ed77abea812. --- agreement/agreementtest/simulate.go | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/agreement/agreementtest/simulate.go b/agreement/agreementtest/simulate.go index 4b2e8b1ca9..b806cdbb40 100644 --- a/agreement/agreementtest/simulate.go +++ b/agreement/agreementtest/simulate.go @@ -92,12 +92,7 @@ func (i *instant) runRound(r basics.Round) { } func (i *instant) shutdown() { - // If Zero() is currently blocked trying to send on Z1, receive once to - // release it; otherwise, don't block shutdown. - select { - case <-i.Z1: - default: - } + <-i.Z1 } func (i *instant) UpdateEventsQueue(queueName string, queueLength int) { From 3410cb16f5b5c04c692d955ab8099fb0adeb30b4 Mon Sep 17 00:00:00 2001 From: cce <51567+cce@users.noreply.github.com> Date: Wed, 10 Sep 2025 14:18:24 -0400 Subject: [PATCH 3/3] upload test logs on failure --- .github/workflows/ci-nightly.yml | 8 ++++++++ .github/workflows/ci-pr.yml | 8 ++++++++ 2 files changed, 16 insertions(+) diff --git a/.github/workflows/ci-nightly.yml b/.github/workflows/ci-nightly.yml index 19381b056c..c1a821cfbb 100644 --- a/.github/workflows/ci-nightly.yml +++ b/.github/workflows/ci-nightly.yml @@ -119,6 +119,14 @@ jobs: job-type: "Test" build-type: "Nightly Build" details: "• Partition: `${{ matrix.partition_id }}` of ${{ env.PARTITION_TOTAL }}\n• Failed Step: `${{ steps.run_tests.name }}`" + - name: Upload test logs on failure + if: failure() + uses: actions/upload-artifact@v4 + with: + name: test-logs-${{ matrix.platform }}-${{ github.run_id }}-${{ matrix.partition_id }} + path: | + **/*.log + retention-days: 30 - name: Upload test artifacts to GitHub uses: actions/upload-artifact@v4 with: diff --git a/.github/workflows/ci-pr.yml b/.github/workflows/ci-pr.yml index 3856e9a65b..18bccfb797 100644 --- a/.github/workflows/ci-pr.yml +++ b/.github/workflows/ci-pr.yml @@ -64,6 +64,14 @@ jobs: job-type: "Test" build-type: "PR Build" details: "• Partition: `${{ matrix.partition_id }}` of ${{ env.PARTITION_TOTAL }}\n• Failed Step: `${{ steps.run_tests.name }}`" + - name: Upload test logs on failure + if: failure() + uses: actions/upload-artifact@v4 + with: + name: test-logs-${{ matrix.platform }}-${{ github.run_id }}-${{ matrix.partition_id }} + path: | + **/*.log + retention-days: 30 - name: Upload test artifacts to GitHub if: ${{ !cancelled() }} uses: actions/upload-artifact@v4