diff --git a/.github/workflows/benchmark.yml b/.github/workflows/benchmark.yml index 689b25c9a..b4631edab 100644 --- a/.github/workflows/benchmark.yml +++ b/.github/workflows/benchmark.yml @@ -8,6 +8,10 @@ on: permissions: contents: write # auto-push to the gh-pages branch +# The second store step skips fetching gh-pages, so it cannot recover +# from a push rejected by a concurrent run. +concurrency: benchmark + jobs: benchmark: runs-on: ubuntu-latest @@ -29,7 +33,8 @@ jobs: tool: 'customSmallerIsBetter' output-file-path: tmp/benchmark/analysis_time.json github-token: ${{ secrets.GITHUB_TOKEN }} - auto-push: true + # Pushed by the next step so that GitHub Pages deploys once per run. + auto-push: false summary-always: true # Shared runners vary by 10-20%; only flag clear regressions. alert-threshold: '150%' @@ -42,6 +47,8 @@ jobs: tool: 'customBiggerIsBetter' output-file-path: tmp/benchmark/type_coverage.json github-token: ${{ secrets.GITHUB_TOKEN }} + # Fetching would fail because the local gh-pages is ahead of the remote. + skip-fetch-gh-pages: true auto-push: true summary-always: true alert-threshold: '100%'