From 18c2a2302ab2f5cf5253dbe0bd849e059ecd45ff Mon Sep 17 00:00:00 2001 From: "python-templates-copier-update[bot]" Date: Sun, 11 Oct 2026 11:27:31 +0000 Subject: [PATCH 1/3] Update from Copier (2026-10-11T11-27-28Z) Signed-off-by: python-templates-copier-update[bot] --- .copier-answers.yaml | 2 +- .github/workflows/build.yaml | 2 +- Makefile | 17 +++++++++++++++++ pyproject.toml | 7 ++++++- 4 files changed, 25 insertions(+), 3 deletions(-) diff --git a/.copier-answers.yaml b/.copier-answers.yaml index 09f8696..fe6b670 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: false add_extension: python diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 2c837c4..10fee28 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 010d07a..d76811c 100644 --- a/Makefile +++ b/Makefile @@ -25,16 +25,26 @@ lint-py: ## lint python with ruff python -m ruff format --check hatch_go lint-docs: ## lint docs with mdformat and codespell +<<<<<<< before updating 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) +>>>>>>> after updating fix-py: ## autoformat python code with ruff python -m ruff check --fix hatch_go python -m ruff format hatch_go fix-docs: ## autoformat docs with mdformat and codespell +<<<<<<< before updating 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) +>>>>>>> after updating lint: lint-py lint-docs ## run all linters lints: lint @@ -49,7 +59,14 @@ format: fix check-manifest: ## check python sdist manifest with check-manifest check-manifest -v +<<<<<<< before updating checks: check-manifest +======= +check-types: ## check python types with ty + ty check --python $$(which python) + +checks: check-dist check-types +>>>>>>> after updating # Alias check: checks diff --git a/pyproject.toml b/pyproject.toml index 0996a3c..a1931ec 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -47,7 +47,12 @@ develop = [ "check-manifest", "codespell>=2.4,<2.5", "hatchling", +<<<<<<< before updating "mdformat>=0.7.22,<1.1", +======= + "mdformat", + "mdformat-frontmatter", +>>>>>>> after updating "mdformat-tables>=1", "pytest", "pytest-cov", @@ -91,7 +96,7 @@ ignore = [ [tool.coverage.run] branch = false omit = [ - "hatch_go/tests/integration/", + "hatch_go/tests/integration/*", ] [tool.coverage.report] From 851765aa0a5288f66dec8d462047cf2b9c7fa5a5 Mon Sep 17 00:00:00 2001 From: Tim Paine <3105306+timkpaine@users.noreply.github.com> Date: Sun, 11 Oct 2026 10:50:08 -0400 Subject: [PATCH 2/3] Update lint and fix commands in Makefile --- Makefile | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/Makefile b/Makefile index d76811c..6c8669f 100644 --- a/Makefile +++ b/Makefile @@ -25,26 +25,16 @@ lint-py: ## lint python with ruff python -m ruff format --check hatch_go lint-docs: ## lint docs with mdformat and codespell -<<<<<<< before updating - 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) ->>>>>>> after updating fix-py: ## autoformat python code with ruff python -m ruff check --fix hatch_go python -m ruff format hatch_go fix-docs: ## autoformat docs with mdformat and codespell -<<<<<<< before updating - 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) ->>>>>>> after updating lint: lint-py lint-docs ## run all linters lints: lint @@ -59,14 +49,10 @@ format: fix check-manifest: ## check python sdist manifest with check-manifest check-manifest -v -<<<<<<< before updating -checks: check-manifest -======= check-types: ## check python types with ty ty check --python $$(which python) checks: check-dist check-types ->>>>>>> after updating # Alias check: checks From f40aa3da6852198f59739dd4a8f7eeb2882a705e Mon Sep 17 00:00:00 2001 From: Tim Paine <3105306+timkpaine@users.noreply.github.com> Date: Sun, 11 Oct 2026 11:11:35 -0400 Subject: [PATCH 3/3] Resolve Copier conflicts and restore manifest checks Signed-off-by: Tim Paine <3105306+timkpaine@users.noreply.github.com> --- Makefile | 12 ++++++------ hatch_go/tests/test_hook_registration.py | 3 ++- hatch_go/tests/test_projects.py | 9 +++++---- pyproject.toml | 4 ---- 4 files changed, 13 insertions(+), 15 deletions(-) diff --git a/Makefile b/Makefile index 6c8669f..e239e45 100644 --- a/Makefile +++ b/Makefile @@ -25,16 +25,16 @@ lint-py: ## lint python with ruff python -m ruff format --check hatch_go 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_go python -m ruff format hatch_go 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 @@ -44,7 +44,7 @@ format: fix ################ # Other Checks # ################ -.PHONY: check-manifest checks check +.PHONY: check-manifest check-types checks check check-manifest: ## check python sdist manifest with check-manifest check-manifest -v @@ -52,7 +52,7 @@ check-manifest: ## check python sdist manifest with check-manifest check-types: ## check python types with ty ty check --python $$(which python) -checks: check-dist check-types +checks: check-manifest check-types # Alias check: checks diff --git a/hatch_go/tests/test_hook_registration.py b/hatch_go/tests/test_hook_registration.py index 7d4be68..3aeba93 100644 --- a/hatch_go/tests/test_hook_registration.py +++ b/hatch_go/tests/test_hook_registration.py @@ -1,4 +1,5 @@ from hatchling.builders.hooks.plugin.interface import BuildHookInterface +from hatchling.metadata.core import ProjectMetadata from hatch_go.hooks import hatch_register_build_hook @@ -10,7 +11,7 @@ def test_registered_build_hook_accepts_hatchling_configuration(tmp_path): root=str(tmp_path), config=config, build_config=None, - metadata=None, + metadata=ProjectMetadata(str(tmp_path), None, {"project": {"name": "project", "version": "0.1.0"}}), directory=str(tmp_path), target_name="wheel", ) diff --git a/hatch_go/tests/test_projects.py b/hatch_go/tests/test_projects.py index bdcf6d7..b38af5e 100644 --- a/hatch_go/tests/test_projects.py +++ b/hatch_go/tests/test_projects.py @@ -1,3 +1,4 @@ +from importlib import import_module from os import listdir from pathlib import Path from shutil import rmtree @@ -61,10 +62,10 @@ def test_basic(self, project_folder): here = Path(__file__).parent / project_folder path.insert(0, str(here)) try: - import project.project + project = import_module("project.project") - assert project.project.hello() == "A string from Go" - assert project.project.add(2, 3) == 5 - assert project.project.add(-1, 1) == 0 + assert project.hello() == "A string from Go" + assert project.add(2, 3) == 5 + assert project.add(-1, 1) == 0 finally: path.remove(str(here)) diff --git a/pyproject.toml b/pyproject.toml index a1931ec..21acf4f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -47,12 +47,8 @@ develop = [ "check-manifest", "codespell>=2.4,<2.5", "hatchling", -<<<<<<< before updating "mdformat>=0.7.22,<1.1", -======= - "mdformat", "mdformat-frontmatter", ->>>>>>> after updating "mdformat-tables>=1", "pytest", "pytest-cov",