From 6572995d8f97d086a302dbec203b30f64457eec1 Mon Sep 17 00:00:00 2001 From: David Matejka Date: Wed, 18 Nov 2026 15:19:35 +0100 Subject: [PATCH 1/2] ci: add job timeouts and concurrency groups Every job gets timeout-minutes: 10; the slowest recent job (publish) took at most 288 s, CI jobs at most 104 s. CI cancels superseded PR runs; publish keeps a per-ref group without cancelling. Co-Authored-By: Claude Opus 5.5 --- .github/workflows/ci.yml | 9 +++++++++ .github/workflows/publish.yml | 6 ++++++ 2 files changed, 15 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 02df95de..c5881bab 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -5,10 +5,15 @@ on: branches: [main] pull_request: +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: ${{ github.event_name == 'pull_request' }} + jobs: lint: name: Lint runs-on: ubuntu-latest + timeout-minutes: 10 steps: - uses: actions/checkout@v6 - uses: oven-sh/setup-bun@v2 @@ -25,6 +30,7 @@ jobs: typecheck: name: Typecheck runs-on: ubuntu-latest + timeout-minutes: 10 steps: - uses: actions/checkout@v6 - uses: oven-sh/setup-bun@v2 @@ -34,6 +40,7 @@ jobs: package-contents: name: Package Contents runs-on: ubuntu-latest + timeout-minutes: 10 steps: - uses: actions/checkout@v6 - uses: oven-sh/setup-bun@v2 @@ -45,6 +52,7 @@ jobs: test: name: Unit & Integration Tests runs-on: ubuntu-latest + timeout-minutes: 10 steps: - uses: actions/checkout@v6 - uses: oven-sh/setup-bun@v2 @@ -54,6 +62,7 @@ jobs: test-browser: name: Browser Tests runs-on: ubuntu-latest + timeout-minutes: 10 services: postgres: image: postgres:16-alpine diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index e70ae02d..f28e063c 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -9,9 +9,15 @@ permissions: id-token: write contents: read +# Never cancel a publish that is already running. +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: false + jobs: publish: runs-on: ubuntu-latest + timeout-minutes: 10 steps: - uses: actions/checkout@v4 with: From 9f7bd21cbffb5174d5e48af25dffe12017f9304b Mon Sep 17 00:00:00 2001 From: David Matejka Date: Wed, 18 Nov 2026 15:21:28 +0100 Subject: [PATCH 2/2] ci: keep every push to main in its own concurrency group A shared group keeps only one pending run, so a quick third push dropped CI for the middle commit. Drop the no-op publish group. Co-Authored-By: Claude Opus 5.5 --- .github/workflows/ci.yml | 3 ++- .github/workflows/publish.yml | 5 ----- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c5881bab..f645e041 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -5,8 +5,9 @@ on: branches: [main] pull_request: +# PRs share a group per ref so a new push cancels the old run; each push to main gets its own group so no commit loses its run. concurrency: - group: ${{ github.workflow }}-${{ github.ref }} + group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && github.ref || github.sha }} cancel-in-progress: ${{ github.event_name == 'pull_request' }} jobs: diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index f28e063c..bd7959ed 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -9,11 +9,6 @@ permissions: id-token: write contents: read -# Never cancel a publish that is already running. -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: false - jobs: publish: runs-on: ubuntu-latest