Skip to content

Commit 4380da8

Browse files
Update from Copier (2026-09-13T10-13-20Z)
Signed-off-by: python-templates-copier-update[bot] <python-templates-copier-update[bot]@users.noreply.github.com>
1 parent 8d241c7 commit 4380da8

6 files changed

Lines changed: 60 additions & 93 deletions

File tree

‎.copier-answers.yaml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Changes here will be overwritten by Copier
2-
_commit: 6a0f1bb
2+
_commit: 5939e98
33
_src_path: https://github.com/python-project-templates/base.git
44
add_docs: true
55
add_extension: cython

‎.github/scripts/test-distributions.py‎

Lines changed: 0 additions & 65 deletions
This file was deleted.

‎.github/workflows/build.yaml‎

Lines changed: 44 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ jobs:
3232
matrix:
3333
platform:
3434
- ubuntu-latest
35-
- ubuntu-24.04-arm
35+
- ubuntu-latest-arm
3636
- macos-latest
3737
- windows-latest
3838
python:
@@ -97,16 +97,54 @@ jobs:
9797
with:
9898
token: ${{ secrets.CODECOV_TOKEN }}
9999

100-
- name: Build distributions
100+
- name: Build distributions (Linux x86_64)
101101
run: |
102-
make clean
102+
rm -rf dist
103+
make dist-py-sdist
103104
make dist-py-wheel
104105
make dist-check
105106
env:
106-
CIBW_BUILD: "${{ matrix.python.cibuildwheel }}-*"
107+
CIBW_BUILD: "${{ matrix.python.cibuildwheel }}-manylinux*"
108+
if: matrix.platform == 'ubuntu-latest'
107109

108-
- name: Test distributions
109-
run: make test-dist
110+
- name: Build distributions (Linux ARM64)
111+
run: |
112+
rm -rf dist
113+
make dist-py-wheel
114+
make dist-check
115+
env:
116+
CIBW_BUILD: "${{ matrix.python.cibuildwheel }}-manylinux*"
117+
if: matrix.platform == 'ubuntu-latest-arm'
118+
119+
- name: Build distributions (macOS)
120+
run: |
121+
rm -rf dist
122+
make dist-py-wheel
123+
make dist-check
124+
env:
125+
CIBW_BUILD: "${{ matrix.python.cibuildwheel }}-macos*"
126+
if: matrix.platform == 'macos-latest'
127+
128+
- name: Build distributions (Windows)
129+
run: |
130+
if (Test-Path dist) { Remove-Item dist -Recurse -Force }
131+
make dist-py-wheel
132+
make dist-check
133+
env:
134+
CIBW_BUILD: "${{ matrix.python.cibuildwheel }}-win_amd64"
135+
if: matrix.platform == 'windows-latest'
136+
137+
- name: Test wheel
138+
uses: actions-ext/python/test-wheel@ec67f82b3bd863948308a41ecb9e70547cbb19c7
139+
with:
140+
module: python_template_cython
141+
if: runner.os == 'Linux'
142+
143+
- name: Test source distribution
144+
uses: actions-ext/python/test-sdist@ec67f82b3bd863948308a41ecb9e70547cbb19c7
145+
with:
146+
module: python_template_cython
147+
if: matrix.platform == 'ubuntu-latest'
110148

111149
- name: Upload distributions
112150
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1

‎Makefile‎

Lines changed: 12 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
.DEFAULT_GOAL := help
2-
.PHONY: develop requirements build install lint-py lint-docs lint lints fix-py fix-docs fix format check-dist check-types checks check test tests coverage show-version patch minor major dist dist-build dist-py-wheel dist-py-sdist dist-check test-dist publish deep-clean clean help
2+
.PHONY: develop requirements build install lint-py lint-docs lint lints fix-py fix-docs fix format check-dist check-types checks check test tests coverage show-version patch minor major dist dist-build dist-py-wheel dist-py-sdist dist-check publish deep-clean clean help
33

44
develop: ## install dependencies and build library
55
uv pip install -e '.[develop]'
@@ -14,16 +14,16 @@ install: ## install library
1414
uv pip install .
1515

1616
lint-py: ## lint Python with ruff
17-
python -m ruff check python_template_cython .github/scripts
18-
python -m ruff format --check python_template_cython .github/scripts
17+
python -m ruff check python_template_cython
18+
python -m ruff format --check python_template_cython
1919

2020
lint-docs: ## lint documentation
2121
python -m mdformat --check README.md docs/development.md
2222
python -m codespell_lib README.md docs/development.md
2323

2424
fix-py: ## autoformat Python code
25-
python -m ruff check --fix python_template_cython .github/scripts
26-
python -m ruff format python_template_cython .github/scripts
25+
python -m ruff check --fix python_template_cython
26+
python -m ruff format python_template_cython
2727

2828
fix-docs: ## autoformat documentation
2929
python -m mdformat README.md docs/development.md
@@ -34,8 +34,8 @@ lints: lint
3434
fix: fix-py fix-docs ## run all autoformatters
3535
format: fix
3636

37-
check-dist: ## check sdist and wheel contents
38-
check-dist -v --rebuild
37+
check-dist: ## check python sdist and wheel with check-dist
38+
check-dist -v
3939

4040
check-types: ## check Python types (advisory)
4141
ty check python_template_cython
@@ -66,18 +66,15 @@ major: ## bump a major version
6666
dist-build: ## build local Python distributions
6767
python -m build -w -s
6868

69-
dist-py-wheel: dist-py-sdist ## build portable native wheels from the sdist
70-
python -m cibuildwheel --output-dir dist dist/*.tar.gz
69+
dist-py-wheel: ## build python wheel
70+
python -m cibuildwheel --output-dir dist
7171

72-
dist-py-sdist: ## build a source distribution
73-
python -m build --sdist --outdir dist
72+
dist-py-sdist: ## build python sdist
73+
python -m build --sdist -o dist
7474

75-
dist-check: ## check distribution metadata
75+
dist-check: ## run python dist checker with twine
7676
python -m twine check dist/*
7777

78-
test-dist: ## test installed wheels and rebuild source distributions
79-
python .github/scripts/test-distributions.py
80-
8178
dist: ## build and check local distributions
8279
$(MAKE) clean
8380
$(MAKE) dist-build

‎docs/development.md‎

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,9 @@ make lint
1111
make checks
1212
make coverage
1313
make dist
14-
make test-dist
1514
```
1615

17-
On Windows, activate with `.venv\Scripts\activate` instead. `make test-dist` installs
18-
compatible wheels in fresh environments and verifies compiled imports outside the
19-
checkout. It also rebuilds each sdist into a wheel and repeats those checks.
16+
On Windows, activate with `.venv\Scripts\activate` instead.
2017

2118
To compile another `.py` or `.pyx` module, add its path to
2219
`[tool.hatch.build.targets.wheel.hooks.cython.options.files].targets` in
@@ -29,7 +26,8 @@ is excluded because builds do not enable Cython line tracing.
2926

3027
For portable wheels, run `make dist-py-wheel` on the target platform. Linux wheel
3128
builds require Docker. Run `make dist-py-sdist` to build an sdist without compiling
32-
extensions. CI runs tests against each installed wheel through cibuildwheel.
29+
extensions. CI runs tests against each installed wheel through cibuildwheel, then
30+
installs the built wheel and sdist in fresh environments to verify they import.
3331

3432
To update the template from a clean branch:
3533

‎pyproject.toml‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,6 @@ develop = [
4444
"hatchling",
4545
"mdformat",
4646
"mdformat-tables>=1",
47-
"packaging",
4847
"pytest",
4948
"pytest-cov",
5049
"ruff",

0 commit comments

Comments
 (0)