From e2674cccccec39aab424932e311f7fec01650a0e Mon Sep 17 00:00:00 2001 From: "python-templates-copier-update[bot]" Date: Sun, 11 Oct 2026 11:26:53 +0000 Subject: [PATCH 1/2] Update from Copier (2026-10-11T11-26-50Z) Signed-off-by: python-templates-copier-update[bot] --- .copier-answers.yaml | 2 +- .github/workflows/build.yaml | 2 +- Makefile | 10 +++++----- pyproject.toml | 3 ++- 4 files changed, 9 insertions(+), 8 deletions(-) diff --git a/.copier-answers.yaml b/.copier-answers.yaml index 07e15d4..218bcb4 100644 --- a/.copier-answers.yaml +++ b/.copier-answers.yaml @@ -1,5 +1,5 @@ # Changes here will be overwritten by Copier -_commit: ebb6e1c +_commit: '4372075' _src_path: https://github.com/python-project-templates/base.git add_docs: true add_extension: python diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 139dd54..b00cdec 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -15,7 +15,7 @@ on: workflow_dispatch: concurrency: - group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} + group: ${{ github.workflow }}-${{ github.ref }} cancel-in-progress: true permissions: diff --git a/Makefile b/Makefile index ca34c97..ee22009 100644 --- a/Makefile +++ b/Makefile @@ -25,16 +25,16 @@ lint-py: ## lint python with ruff python -m ruff format --check hatch_multi lint-docs: ## lint docs with mdformat and codespell - python -m mdformat --check README.md - python -m codespell_lib README.md + python -m mdformat --check README.md $(wildcard docs/src) + python -m codespell_lib README.md $(wildcard docs/src) fix-py: ## autoformat python code with ruff python -m ruff check --fix hatch_multi python -m ruff format hatch_multi fix-docs: ## autoformat docs with mdformat and codespell - python -m mdformat README.md - python -m codespell_lib --write README.md + python -m mdformat README.md $(wildcard docs/src) + python -m codespell_lib --write README.md $(wildcard docs/src) lint: lint-py lint-docs ## run all linters lints: lint @@ -52,7 +52,7 @@ check-dist: ## check python sdist and wheel with check-dist check-types: ## check python types with ty ty check --python $$(which python) -checks: check-dist +checks: check-dist check-types # Alias check: checks diff --git a/pyproject.toml b/pyproject.toml index 4559c4a..d4a66e8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -44,6 +44,7 @@ develop = [ "codespell", "hatchling", "mdformat", + "mdformat-frontmatter", "mdformat-tables>=1", "pytest", "pytest-cov", @@ -78,7 +79,7 @@ replace = 'version = "{new_version}"' [tool.coverage.run] omit = [ - "hatch_multi/tests/integration/", + "hatch_multi/tests/integration/*", ] [tool.coverage.report] From 7cd3f4d482a660b84d41415475507b736315051d Mon Sep 17 00:00:00 2001 From: Tim Paine <3105306+timkpaine@users.noreply.github.com> Date: Sun, 11 Oct 2026 10:58:07 -0400 Subject: [PATCH 2/2] Use validation aliases for dependency sets Signed-off-by: Tim Paine <3105306+timkpaine@users.noreply.github.com> --- Makefile | 8 ++++---- hatch_multi/structs.py | 2 +- hatch_multi/tests/test_structs.py | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Makefile b/Makefile index ee22009..f784bd5 100644 --- a/Makefile +++ b/Makefile @@ -25,16 +25,16 @@ lint-py: ## lint python with ruff python -m ruff format --check hatch_multi lint-docs: ## lint docs with mdformat and codespell - python -m mdformat --check README.md $(wildcard docs/src) - python -m codespell_lib README.md $(wildcard docs/src) + python -m mdformat --check README.md $(wildcard docs/src) + python -m codespell_lib README.md $(wildcard docs/src) fix-py: ## autoformat python code with ruff python -m ruff check --fix hatch_multi python -m ruff format hatch_multi fix-docs: ## autoformat docs with mdformat and codespell - python -m mdformat README.md $(wildcard docs/src) - python -m codespell_lib --write README.md $(wildcard docs/src) + python -m mdformat README.md $(wildcard docs/src) + python -m codespell_lib --write README.md $(wildcard docs/src) lint: lint-py lint-docs ## run all linters lints: lint diff --git a/hatch_multi/structs.py b/hatch_multi/structs.py index 054fa08..d88c3d3 100644 --- a/hatch_multi/structs.py +++ b/hatch_multi/structs.py @@ -10,5 +10,5 @@ class HatchMultiConfig(BaseModel, validate_assignment=True): primary: str | list[str] | None = Field( default=None, description="Optional dependency set/s to use as primary", - alias=AliasChoices("primary", "default"), + validation_alias=AliasChoices("primary", "default"), ) diff --git a/hatch_multi/tests/test_structs.py b/hatch_multi/tests/test_structs.py index bb38115..c77357a 100644 --- a/hatch_multi/tests/test_structs.py +++ b/hatch_multi/tests/test_structs.py @@ -6,5 +6,5 @@ def test_config(self): config = HatchMultiConfig(name="test", primary="default") assert config.primary == "default" - config = HatchMultiConfig(name="test", default="default") + config = HatchMultiConfig.model_validate({"name": "test", "default": "default"}) assert config.primary == "default"