Skip to content
Draft
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
27 changes: 27 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,33 @@ jobs:
- name: Run tests
run: uv run --python ${{ matrix.python-version }} --with=".[dev]" pytest --cov --cov-report=''

templates:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
template: [coding, cua]

steps:
- name: Check out code
uses: actions/checkout@v4

- name: Install uv
uses: astral-sh/setup-uv@v5

- name: Install template with the SDK from this checkout
working-directory: environments/${{ matrix.template }}
run: |
uv sync --all-extras

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Enforce the checked-in template locks

For both matrix entries, if a PR changes environments/<template>/pyproject.toml without updating its uv.lock, this command silently regenerates the lock in the runner and tests that uncommitted state, allowing CI to pass while the checked-in reproducible environment remains stale. uv sync --help documents --locked as “Assert that the uv.lock will remain unchanged”; use that option here so dependency and lock changes must be committed together.

Useful? React with 👍 / 👎.

uv pip install -e ../..

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Resolve the checkout in a clean template dependency graph

When the checkout removes a dependency previously supplied by the released hud package, the preceding sync installs that old dependency from the template lock and this additive editable install leaves it behind. Template tests can therefore keep importing an undeclared dependency and pass even though a clean installation against the checkout would fail; uv pip install --help confirms that removing extraneous packages requires --exact. Resolve hud from ../.. as part of the template environment rather than layering it over the released package's dependency set.

Useful? React with 👍 / 👎.


- name: Run template checks
working-directory: environments/${{ matrix.template }}
run: |
uv run --no-sync ruff format . --check
uv run --no-sync ruff check .
uv run --no-sync pytest -q

lint-ruff:
runs-on: ubuntu-latest
steps:
Expand Down