Skip to content

Commit 3979451

Browse files
committed
Switch to uv build
1 parent be13d93 commit 3979451

File tree

12 files changed

+24
-10
lines changed

12 files changed

+24
-10
lines changed

.github/workflows/release.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,11 @@ jobs:
2222
submodules: true
2323
persist-credentials: false
2424

25+
- name: Install the latest version of uv
26+
uses: astral-sh/setup-uv@bd01e18f51369d5a26f1651c3cb451d3417e3bba # 6.3.1
27+
2528
- name: Build
26-
run: pipx run build
29+
run: uv build
2730

2831
- uses: actions/upload-artifact@v4
2932
with:

HISTORY.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,12 @@
44
History
55
-------
66

7+
5.2.0
8+
++++++++++++++++++
9+
10+
* Setuptools has been replaced with the uv build backend for building the
11+
package.
12+
713
5.1.0 (2025-05-05)
814
++++++++++++++++++
915

pyproject.toml

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -41,11 +41,19 @@ lint = [
4141
]
4242

4343
[build-system]
44-
requires = [
45-
"setuptools>=77.0.3",
46-
"setuptools-scm",
44+
requires = ["uv_build>=0.7.19,<0.8.0"]
45+
build-backend = "uv_build"
46+
47+
[tool.uv.build-backend]
48+
source-include = [
49+
"HISTORY.rst",
50+
"README.rst",
51+
"LICENSE",
52+
"docs/html",
53+
"examples/*.py",
54+
"tests/*.py",
55+
"tests/data/test-data/*.mmdb"
4756
]
48-
build-backend = "setuptools.build_meta"
4957

5058
[project.urls]
5159
Homepage = "https://www.maxmind.com/"
@@ -81,12 +89,9 @@ ignore = [
8189

8290
[tool.ruff.lint.per-file-ignores]
8391
"docs/*" = ["ALL"]
84-
"geoip2/{models,records}.py" = [ "D107", "PLR0913" ]
92+
"src/geoip2/{models,records}.py" = [ "D107", "PLR0913" ]
8593
"tests/*" = ["ANN201", "D"]
8694

87-
[tool.setuptools.package-data]
88-
geoip2 = ["py.typed"]
89-
9095
[tool.tox]
9196
env_list = [
9297
"3.9",
@@ -114,7 +119,7 @@ dependency_groups = [
114119
"lint",
115120
]
116121
commands = [
117-
["mypy", "geoip2", "tests"],
122+
["mypy", "src", "tests"],
118123
["ruff", "check"],
119124
["ruff", "format", "--check", "--diff", "."],
120125
]
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)