From ba5ce99fbdaf6700dcac11ca3998d73f76041473 Mon Sep 17 00:00:00 2001 From: tangym Date: Wed, 17 Jun 2026 22:23:23 +0000 Subject: [PATCH 1/3] ci(build): scope Python build to Python paths MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add a paths filter to the push and pull_request triggers of build.yml so the Python sdist/wheel build and cross-platform install smoke tests only run when Python-relevant files change (assert_ai/, tests/, pyproject.toml, uv.lock, pytest.ini, or this workflow itself). The viewer/ frontend is fully standalone — verified by: grep -r 'viewer' assert_ai/ tests/ --include='*.py' -l -> 0 matches so excluding viewer-only changes from the Python build does not skip anything that would catch a Python regression. workflow_dispatch is intentionally left unfiltered so the Python build can still be run manually against any branch. --- .github/workflows/build.yml | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index ba90f571..0dafe0c3 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -3,8 +3,22 @@ name: Build on: push: branches: [main] + paths: + - 'assert_ai/**' + - 'tests/**' + - 'pyproject.toml' + - 'uv.lock' + - 'pytest.ini' + - '.github/workflows/build.yml' pull_request: branches: [main] + paths: + - 'assert_ai/**' + - 'tests/**' + - 'pyproject.toml' + - 'uv.lock' + - 'pytest.ini' + - '.github/workflows/build.yml' workflow_dispatch: permissions: From 93418049e6e38eaecd3dbcd1a15bfe81149f3a03 Mon Sep 17 00:00:00 2001 From: tangym Date: Wed, 17 Jun 2026 22:23:42 +0000 Subject: [PATCH 2/3] ci(viewer): add path-scoped build workflow for viewer/ MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add a dedicated GitHub Actions workflow that installs the viewer/ lockfile, runs svelte-check, and runs vite build whenever something under viewer/ (or this workflow file itself) changes. Motivation: PR #240 (Dependabot Svelte bumps) had no CI coverage for the frontend, so frontend regressions are caught manually. This adds an automated gate while keeping viewer/ and the Python build fully decoupled — the two workflows use disjoint paths filters so a Python-only PR does not pay for a Node build and a viewer-only PR does not wait on Python jobs. Locally validated on a clean checkout: npm ci + npm run check (0 errors) + npm run build (5.56s) all succeed against the current viewer/ tree. --- .github/workflows/build-viewer.yml | 44 ++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 .github/workflows/build-viewer.yml diff --git a/.github/workflows/build-viewer.yml b/.github/workflows/build-viewer.yml new file mode 100644 index 00000000..e9b747b9 --- /dev/null +++ b/.github/workflows/build-viewer.yml @@ -0,0 +1,44 @@ +name: Build (viewer) + +# Gates the Svelte/SvelteKit frontend in viewer/. Triggered only by changes +# under viewer/ (or this workflow itself), so Python-only PRs do not pay for +# a Node build and viewer-only PRs (notably Dependabot frontend bumps) do +# not need to wait on Python jobs. +# +# Mirrors the equivalent Node steps Dependabot PRs need to validate: +# - install with the committed lockfile (npm ci) +# - svelte-check (type + a11y diagnostics) +# - vite build + +on: + push: + branches: [main] + paths: + - 'viewer/**' + - '.github/workflows/build-viewer.yml' + pull_request: + branches: [main] + paths: + - 'viewer/**' + - '.github/workflows/build-viewer.yml' + workflow_dispatch: + +permissions: + contents: read + +jobs: + viewer-build: + runs-on: ubuntu-latest + defaults: + run: + working-directory: viewer + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 + with: + node-version: '20' + cache: 'npm' + cache-dependency-path: viewer/package-lock.json + - run: npm ci + - run: npm run check + - run: npm run build From 755c0bfad90d20d65686116184942457a707f8a7 Mon Sep 17 00:00:00 2001 From: tangym Date: Wed, 17 Jun 2026 23:04:30 +0000 Subject: [PATCH 3/3] ci(build): include README.md and LICENSE in Python build paths pyproject.toml references README.md (readme) and LICENSE (license.file) as packaging inputs. Without these in the paths filter, a PR that only renames/deletes/edits either file would skip the Python build and any resulting `python -m build` / `twine check` failure would slip through until the next Python-code PR. Pure trigger widening: no jobs or steps changed. Addresses Copilot review feedback on PR #245. --- .github/workflows/build.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 0dafe0c3..12637900 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -9,6 +9,8 @@ on: - 'pyproject.toml' - 'uv.lock' - 'pytest.ini' + - 'README.md' + - 'LICENSE' - '.github/workflows/build.yml' pull_request: branches: [main] @@ -18,6 +20,8 @@ on: - 'pyproject.toml' - 'uv.lock' - 'pytest.ini' + - 'README.md' + - 'LICENSE' - '.github/workflows/build.yml' workflow_dispatch: