Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 24 additions & 15 deletions .github/workflows/ci-host.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,9 @@ jobs:
uses: ./.github/workflows/test-web-assets.yaml
with:
skip_catalog: true
concurrency:
group: ci-host-test-web-assets-${{ github.head_ref || github.run_id }}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Include fork identity in new concurrency groups

On pull_request runs, github.head_ref is only the source branch name. This new group key will therefore collide for unrelated PRs from different forks that both use a common branch name such as main or patch-1, so one contributor's push can cancel another PR's host asset build. Including the fork repo (or PR number) in the group would avoid these cross-PR cancellations.

Useful? React with 👍 / 👎.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Historically we haven’t been getting PRs from forks, but we can revisit this if it becomes a problem

cancel-in-progress: true

host-test:
name: Host Tests
Expand Down Expand Up @@ -115,16 +118,16 @@ jobs:

- name: Upload junit report to GitHub Actions Artifacts
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # 4.6.1
if: always()
if: ${{ !cancelled() }}
with:
name: host-test-report-${{ matrix.shardIndex }}
path: junit/host-${{ matrix.shardIndex }}.xml
retention-days: 30
- name: Print realm server logs
if: always()
if: ${{ !cancelled() }}
run: cat /tmp/server.log
- name: Extract worker and prerender logs
if: always()
if: ${{ !cancelled() }}
run: |
grep -E '^\[start:worker-development' /tmp/server.log > /tmp/worker-manager.log || true
grep -E '^\[start:prerender-dev' /tmp/server.log > /tmp/prerender-server.log || true
Expand All @@ -133,64 +136,67 @@ jobs:
grep -E '^\[start:test-realms|^\[start:worker-test' /tmp/server.log > /tmp/test-realms.log || true
- name: Upload realm server log
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # 4.6.1
if: always()
if: ${{ !cancelled() }}
with:
name: realm-server-log-${{ matrix.shardIndex }}
path: /tmp/server.log
retention-days: 30
- name: Upload worker manager log
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # 4.6.1
if: always()
if: ${{ !cancelled() }}
with:
name: worker-manager-log-${{ matrix.shardIndex }}
path: /tmp/worker-manager.log
retention-days: 30
- name: Upload prerender server log
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # 4.6.1
if: always()
if: ${{ !cancelled() }}
with:
name: prerender-server-log-${{ matrix.shardIndex }}
path: /tmp/prerender-server.log
retention-days: 30
- name: Upload prerender manager log
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # 4.6.1
if: always()
if: ${{ !cancelled() }}
with:
name: prerender-manager-log-${{ matrix.shardIndex }}
path: /tmp/prerender-manager.log
retention-days: 30
- name: Upload start:development log
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # 4.6.1
if: always()
if: ${{ !cancelled() }}
with:
name: start-development-log-${{ matrix.shardIndex }}
path: /tmp/start-development.log
retention-days: 30
- name: Upload test-realms log
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # 4.6.1
if: always()
if: ${{ !cancelled() }}
with:
name: test-realms-log-${{ matrix.shardIndex }}
path: /tmp/test-realms.log
retention-days: 30
- name: Upload testem log
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # 4.6.1
if: always()
if: ${{ !cancelled() }}
with:
name: testem-log-${{ matrix.shardIndex }}
path: junit/host-testem.log
retention-days: 30
- name: Upload icon server log
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # 4.6.1
if: always()
if: ${{ !cancelled() }}
with:
name: icon-server-log-${{ matrix.shardIndex }}
path: /tmp/icon-server.log
retention-days: 30

host-percy-finalize:
name: Finalise Percy
if: always()
if: ${{ !cancelled() }}
concurrency:
group: host-percy-finalize-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
needs: host-test
runs-on: ubuntu-latest

Expand All @@ -207,7 +213,10 @@ jobs:

host-merge-reports-and-publish:
name: Merge Host reports and publish
if: always()
if: ${{ !cancelled() }}
concurrency:
group: host-merge-reports-and-publish-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
needs: host-test
runs-on: ubuntu-latest

Expand All @@ -234,15 +243,15 @@ jobs:

- name: Upload merged report
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # 4.6.1
if: always()
if: ${{ !cancelled() }}
with:
name: host-test-report-merged
path: host.xml
retention-days: 30

- name: Publish test results
uses: EnricoMi/publish-unit-test-result-action@170bf24d20d201b842d7a52403b73ed297e6645b # 2.18.0
if: always()
if: ${{ !cancelled() }}
with:
junit_files: host.xml
check_name: Host Test Results
40 changes: 20 additions & 20 deletions .github/workflows/ci-lint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,84 +23,84 @@ jobs:
- uses: ./.github/actions/init

- name: Lint Boxel Icons
if: always()
if: ${{ !cancelled() }}
run: pnpm run lint
working-directory: packages/boxel-icons
- name: Build Boxel Icons
# To faciliate linting of projects that depend on Boxel Icons
if: always()
if: ${{ !cancelled() }}
run: pnpm run build
working-directory: packages/boxel-icons
- name: Lint Boxel UI
if: always()
if: ${{ !cancelled() }}
run: pnpm run lint
working-directory: packages/boxel-ui/addon
- name: Build Boxel UI
# To faciliate linting of projects that depend on Boxel UI
if: always()
if: ${{ !cancelled() }}
run: pnpm run build
working-directory: packages/boxel-ui/addon
- name: Lint Boxel UI Test App
if: always()
if: ${{ !cancelled() }}
run: pnpm run lint
working-directory: packages/boxel-ui/test-app
- name: Lint Host
if: always()
if: ${{ !cancelled() }}
run: pnpm run lint
working-directory: packages/host
- name: Lint Matrix
if: always()
if: ${{ !cancelled() }}
run: pnpm run lint
working-directory: packages/matrix
- name: Lint Realm Server
if: always()
if: ${{ !cancelled() }}
run: pnpm run lint
working-directory: packages/realm-server
- name: Lint Runtime Common
if: always()
if: ${{ !cancelled() }}
run: pnpm run lint
working-directory: packages/runtime-common
- name: Lint Billing
if: always()
if: ${{ !cancelled() }}
run: pnpm run lint
working-directory: packages/billing
- name: Lint Postgres
if: always()
if: ${{ !cancelled() }}
run: pnpm run lint
working-directory: packages/postgres
- name: Lint Base Realm
if: always()
if: ${{ !cancelled() }}
run: pnpm run lint
working-directory: packages/base
- name: Lint Catalog Realm
if: always()
if: ${{ !cancelled() }}
run: pnpm run lint
working-directory: packages/catalog-realm
- name: Lint Experiments Realm
if: always()
if: ${{ !cancelled() }}
run: pnpm run lint
working-directory: packages/experiments-realm
- name: Lint Software Factory
if: always()
if: ${{ !cancelled() }}
run: pnpm run lint
working-directory: packages/software-factory
- name: Lint Boxel Tools VS Code extension
if: always()
if: ${{ !cancelled() }}
run: pnpm run lint
working-directory: packages/vscode-boxel-tools
- name: Lint ESLint Plugin
if: always()
if: ${{ !cancelled() }}
run: pnpm run lint
working-directory: packages/eslint-plugin-boxel
- name: Lint AI Bot
if: always()
if: ${{ !cancelled() }}
run: pnpm run lint
working-directory: packages/ai-bot
- name: Lint Bot Runner
if: always()
if: ${{ !cancelled() }}
run: pnpm run lint
working-directory: packages/bot-runner
- name: Lint Workspace Sync CLI
if: always()
if: ${{ !cancelled() }}
run: pnpm run lint
working-directory: packages/workspace-sync-cli
42 changes: 24 additions & 18 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,9 @@ jobs:
needs: change-check
if: needs.change-check.outputs.boxel == 'true' || needs.change-check.outputs.boxel-ui == 'true' || needs.change-check.outputs.matrix == 'true' || needs.change-check.outputs.realm-server == 'true' || needs.change-check.outputs.software-factory == 'true' || needs.change-check.outputs.vscode-boxel-tools == 'true' || needs.change-check.outputs.workspace-sync-cli == 'true' || github.ref == 'refs/heads/main' || needs.change-check.outputs.run_all == 'true'
uses: ./.github/workflows/test-web-assets.yaml
concurrency:
group: ci-test-web-assets-${{ github.head_ref || github.run_id }}
cancel-in-progress: true

ai-bot-test:
name: AI bot Tests
Expand Down Expand Up @@ -329,38 +332,38 @@ jobs:
run: pnpm test:group ${{ matrix.shardIndex }}/${{ matrix.shardTotal }}
working-directory: packages/matrix
- name: Print realm server logs
if: always()
if: ${{ !cancelled() }}
run: cat /tmp/server.log
- name: Extract worker and prerender logs
if: always()
if: ${{ !cancelled() }}
run: |
grep -E '^\[start:worker-base|^\[start:worker-development|^\[start:worker-test' /tmp/server.log > /tmp/worker-manager.log || true
grep -E '^\[start:prerender-dev' /tmp/server.log > /tmp/prerender-server.log || true
grep -E '^\[start:prerender-manager-dev' /tmp/server.log > /tmp/prerender-manager.log || true
- name: Upload realm server log
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # 4.6.1
if: always()
if: ${{ !cancelled() }}
with:
name: matrix-test-realm-server-log-${{ matrix.shardIndex }}
path: /tmp/server.log
retention-days: 30
- name: Upload worker manager log
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # 4.6.1
if: always()
if: ${{ !cancelled() }}
with:
name: matrix-test-worker-manager-log-${{ matrix.shardIndex }}
path: /tmp/worker-manager.log
retention-days: 30
- name: Upload prerender server log
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # 4.6.1
if: always()
if: ${{ !cancelled() }}
with:
name: matrix-test-prerender-server-log-${{ matrix.shardIndex }}
path: /tmp/prerender-server.log
retention-days: 30
- name: Upload prerender manager log
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # 4.6.1
if: always()
if: ${{ !cancelled() }}
with:
name: matrix-test-prerender-manager-log-${{ matrix.shardIndex }}
path: /tmp/prerender-manager.log
Expand Down Expand Up @@ -388,9 +391,12 @@ jobs:
needs:
- change-check
- matrix-client-test
# always() makes it run even if a matrix-client-test shard fails
if: always() && (needs.change-check.outputs.matrix == 'true' || github.ref == 'refs/heads/main' || needs.change-check.outputs.run_all == 'true')
# !cancelled() makes it run even if a matrix-client-test shard fails, but still respects cancellation
if: ${{ !cancelled() && (needs.change-check.outputs.matrix == 'true' || github.ref == 'refs/heads/main' || needs.change-check.outputs.run_all == 'true') }}
runs-on: ubuntu-latest
concurrency:
group: matrix-client-merge-reports-${{ github.head_ref || github.run_id }}
cancel-in-progress: true

permissions:
id-token: write
Expand Down Expand Up @@ -584,16 +590,16 @@ jobs:
env:
TEST_MODULE: ${{matrix.testModule}}
- name: Print realm server logs
if: always()
if: ${{ !cancelled() }}
run: cat /tmp/server.log
- name: Prepare artifact name
id: artifact_name
if: always()
if: ${{ !cancelled() }}
run: |
export SAFE_ARTIFACT_NAME=$(echo ${{ matrix.testModule }} | sed 's/[/]/_/g')
echo "artifact_name=$SAFE_ARTIFACT_NAME" >> "$GITHUB_OUTPUT"
- name: Extract worker and prerender logs
if: always()
if: ${{ !cancelled() }}
run: |
grep -E '^\[start:worker-development|^\[start:worker-test' /tmp/server.log > /tmp/worker-manager.log || true
grep -E '^\[start:prerender-dev' /tmp/server.log > /tmp/prerender-server.log || true
Expand All @@ -602,42 +608,42 @@ jobs:
grep -E '^\[start:test-realms|^\[start:worker-test' /tmp/server.log > /tmp/test-realms.log || true
- name: Upload realm server log
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # 4.6.1
if: always()
if: ${{ !cancelled() }}
with:
name: realm-server-test-realm-server-log-${{steps.artifact_name.outputs.artifact_name}}
path: /tmp/server.log
retention-days: 30
- name: Upload worker manager log
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # 4.6.1
if: always()
if: ${{ !cancelled() }}
with:
name: realm-server-test-worker-manager-log-${{steps.artifact_name.outputs.artifact_name}}
path: /tmp/worker-manager.log
retention-days: 30
- name: Upload prerender server log
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # 4.6.1
if: always()
if: ${{ !cancelled() }}
with:
name: realm-server-test-prerender-server-log-${{steps.artifact_name.outputs.artifact_name}}
path: /tmp/prerender-server.log
retention-days: 30
- name: Upload prerender manager log
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # 4.6.1
if: always()
if: ${{ !cancelled() }}
with:
name: realm-server-test-prerender-manager-log-${{steps.artifact_name.outputs.artifact_name}}
path: /tmp/prerender-manager.log
retention-days: 30
- name: Upload start:development log
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # 4.6.1
if: always()
if: ${{ !cancelled() }}
with:
name: realm-server-test-start-development-log-${{steps.artifact_name.outputs.artifact_name}}
path: /tmp/start-development.log
retention-days: 30
- name: Upload test-realms log
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # 4.6.1
if: always()
if: ${{ !cancelled() }}
with:
name: realm-server-test-test-realms-log-${{steps.artifact_name.outputs.artifact_name}}
path: /tmp/test-realms.log
Expand Down Expand Up @@ -786,7 +792,7 @@ jobs:
working-directory: packages/workspace-sync-cli
- name: Upload test services log
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # 4.6.1
if: always()
if: ${{ !cancelled() }}
with:
name: workspace-sync-cli-test-services-log
path: /tmp/test-services.log
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/diff-skills.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,6 @@ jobs:
diff-skills:
uses: cardstack/gh-actions/.github/workflows/diff-skills.yml@main
secrets: inherit
concurrency:
group: diff-skills-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
Loading
Loading