aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTSRBerry <20988865+TSRBerry@users.noreply.github.com>2023-08-01 00:15:37 +0200
committerGitHub <noreply@github.com>2023-08-01 00:15:37 +0200
commitbedee64af5a36a55b82df781b3bc78f9d09844c6 (patch)
treef1f6e286e8313767268da120f50ad9d1ff528ed0
parent86931cc3f1f781f8849651e658a222ca821040fa (diff)
Add slightly better workaround for current workflow issues (#5507)
* checks: Add retry logic to dotnet format style step as well I can't imagine dotnet format whitespace ever segfaulting, so hopefully it won't be needed there. * checks: Replace bash scripts with unstable-commands action * build: Add unstable-commands action for test step
-rw-r--r--.github/workflows/build.yml8
-rw-r--r--.github/workflows/checks.yml28
2 files changed, 20 insertions, 16 deletions
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index c93fd0d3..dc372870 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -54,7 +54,11 @@ jobs:
run: dotnet build -c "${{ matrix.configuration }}" -p:Version="${{ env.RYUJINX_BASE_VERSION }}" -p:SourceRevisionId="${{ steps.git_short_hash.outputs.result }}" -p:ExtraDefineConstants=DISABLE_UPDATER
- name: Test
- run: dotnet test --no-build -c "${{ matrix.configuration }}"
+ uses: TSRBerry/unstable-commands@v1
+ with:
+ commands: dotnet test --no-build -c "${{ matrix.configuration }}"
+ timeout-minutes: 10
+ retry-codes: 139
- name: Publish Ryujinx
run: dotnet publish -c "${{ matrix.configuration }}" -r "${{ matrix.DOTNET_RUNTIME_IDENTIFIER }}" -o ./publish -p:Version="${{ env.RYUJINX_BASE_VERSION }}" -p:DebugType=embedded -p:SourceRevisionId="${{ steps.git_short_hash.outputs.result }}" -p:ExtraDefineConstants=DISABLE_UPDATER src/Ryujinx --self-contained true
@@ -141,4 +145,4 @@ jobs:
with:
name: ava-ryujinx-${{ matrix.configuration }}-${{ env.RYUJINX_BASE_VERSION }}+${{ steps.git_short_hash.outputs.result }}-macos_universal
path: "publish_ava/*.tar.gz"
- if: github.event_name == 'pull_request' \ No newline at end of file
+ if: github.event_name == 'pull_request'
diff --git a/.github/workflows/checks.yml b/.github/workflows/checks.yml
index c34d196f..94d0a342 100644
--- a/.github/workflows/checks.yml
+++ b/.github/workflows/checks.yml
@@ -40,23 +40,23 @@ jobs:
run: |
dotnet format whitespace --verify-no-changes --report ./whitespace-report.json -v d
+ # For some unknown reason this step sometimes fails with exit code 139 (segfault?),
+ # so in that case we'll try again (3 tries max).
- name: Run dotnet format style
- run: |
- dotnet format style --severity info --verify-no-changes --report ./style-report.json -v d
+ uses: TSRBerry/unstable-commands@v1
+ with:
+ commands: dotnet format style --severity info --verify-no-changes --report ./style-report.json -v d
+ timeout-minutes: 5
+ retry-codes: 139
- # For some reason this step sometimes fails with exit code 139 (segfault?),
- # so should that be the case we'll try again (3 tries max).
+ # For some unknown reason this step sometimes fails with exit code 139 (segfault?),
+ # so in that case we'll try again (3 tries max).
- name: Run dotnet format analyzers
- run: |
- attempt=0
- exit_code=139
- until [ $attempt -ge 3 ] || [ $exit_code -ne 139 ]; do
- ((attempt+=1))
- exit_code=0
- echo "Attempt: ${attempt}/3"
- dotnet format analyzers --severity info --verify-no-changes --report ./analyzers-report.json -v d || exit_code=$?
- done
- exit $exit_code
+ uses: TSRBerry/unstable-commands@v1
+ with:
+ commands: dotnet format analyzers --severity info --verify-no-changes --report ./analyzers-report.json -v d
+ timeout-minutes: 5
+ retry-codes: 139
- name: Upload report
if: failure()