From 68d9ad862f1ebf680ff6fc5366eceef6e0252907 Mon Sep 17 00:00:00 2001 From: Binary Alley Date: Wed, 2 Sep 2026 12:29:07 -0700 Subject: [PATCH] Prevents test workflow jobs from hanging indefinitely --- .github/workflows/run-tests.yml | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index 1b43726a..8aa5ace1 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -9,6 +9,7 @@ on: jobs: run-platform-tests: runs-on: ${{ matrix.os }} + timeout-minutes: 60 strategy: matrix: os: [ubuntu-latest, windows-latest, macOS-latest] @@ -26,4 +27,15 @@ jobs: - name: Build run: dotnet build src/Lumina.sln --no-restore -p:SixLaborsLicenseEnforceBuild=true - name: Run tests - run: dotnet test src/Lumina.sln --no-build --verbosity normal + # blame-hang terminates a test that blocks for 10 minutes and dumps the hang stack, + # turning the recurring 'stuck job' into a failing job that names the culprit test + run: dotnet test src/Lumina.sln --no-build --verbosity normal --blame-hang --blame-hang-timeout 10m + - name: Upload hang diagnostics + if: failure() + uses: actions/upload-artifact@v4 + with: + name: test-hang-diagnostics-${{ matrix.os }} + path: | + **/TestResults/**/*.dmp + **/TestResults/**/*.log + if-no-files-found: ignore