Skip to content

Commit 628d7c0

Browse files
committed
Use dependency groups
1 parent 8694416 commit 628d7c0

6 files changed

Lines changed: 33 additions & 8 deletions

File tree

.github/workflows/ci.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ jobs:
2727
fail-fast: false
2828
matrix:
2929
os: [ubuntu-latest, macos-latest, windows-latest]
30-
python-version: ['3.10', '3.11', '3.12', '3.13', 3.14]
30+
python-version: ['3.10', '3.11', '3.12', '3.13', '3.14']
3131
# include:
3232
# - os: ubuntu-latest
3333
# python-version: 'pypy3.9'
@@ -62,7 +62,7 @@ jobs:
6262
- name: Install test dependencies
6363
shell: bash
6464
run: |
65-
python -m pip install pytest
65+
python -m pip install --group test
6666
if [ -f requirements-test.txt ]; then pip install -r requirements-test.txt; fi
6767
6868
- name: Test with pytest
@@ -154,6 +154,7 @@ jobs:
154154
shell: bash
155155
run: |
156156
python -m pip install --upgrade setuptools pip
157+
python -m pip install --group dev
157158
if [ -f requirements-dev.txt ]; then python -m pip install -r requirements-dev.txt; fi
158159
159160
- name: Build and install

.github/workflows/docs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ jobs:
3030
shell: bash
3131
run: |
3232
python -m pip install --upgrade pip
33-
python -m pip install sphinx sphinxcontrib-spelling
33+
python -m pip install --group docs
3434
python -m pip install .
3535
if [ -f requirements-dev.txt ]; then python -m pip install -r requirements-dev.txt; fi
3636

.github/workflows/lint.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ jobs:
3030
shell: bash
3131
run: |
3232
python -m pip install --upgrade pip
33-
python -m pip install flake8 pydocstyle black ruff # isort mypy
33+
python -m pip install --group lint
3434
if [ -f requirements-lint.txt ]; then pip install -r requirements-lint.txt; fi
3535
3636
- name: Lint (flake8)

Makefile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,6 @@ lint:
8484
$(PYTHON) -m black --check src/$(TARGET) tests
8585
# $(PYTHON) -m mypy --check-untyped-defs --ignore-missing-imports src/$(TARGET)
8686
ruff check src/$(TARGET) tests
87-
# ruff check $(TARGET) tests
8887
# codespell
8988

9089
docs:

pyproject.toml

Lines changed: 27 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ requires = [
33
"setuptools >=77.0.0",
44
"packaging",
55
"cython >=3.0",
6-
"numpy",
6+
"numpy >=2",
77
]
88
build-backend = "setuptools.build_meta"
99

@@ -36,7 +36,7 @@ classifiers = [
3636
"Topic :: Scientific/Engineering :: GIS",
3737
]
3838
dependencies = [
39-
"numpy>=1.7",
39+
"numpy >=1.26.4",
4040
]
4141
dynamic = ["version"]
4242

@@ -69,6 +69,31 @@ Changelog = "https://pyepr.readthedocs.io/en/latest/NEWS.html"
6969
Issues = "https://github.com/avalentino/pyepr/issues"
7070

7171

72+
[dependency-groups]
73+
docs = [
74+
"sphinx",
75+
"sphinx_rtd_theme",
76+
"sphinxcontrib-spelling",
77+
"packaginhg",
78+
"ipython",
79+
]
80+
test = ["pytest", "packaging"]
81+
coverage = ["pytest-cov", "coverage[toml]", {include-group = "test"}]
82+
lint = ["flake8", "pydocstyle", "isort", "black", "ruff"]
83+
dev = [
84+
"python-build",
85+
"twine",
86+
"setuptools >=77",
87+
"packaging",
88+
"cython>=3",
89+
"numpy>=2",
90+
{include-group = "docs"},
91+
{include-group = "test"},
92+
{include-group = "coverage"},
93+
{include-group = "lint"},
94+
]
95+
96+
7297
[tool.setuptools]
7398
packages = ["epr"]
7499
package-dir = {"" = "src"}

requirements-dev.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
coverage
22
cython>=3.0
33
ipython
4-
numpy>=1.7
4+
numpy>=1.26.4
55
packaging
66
pytest
77
pytest-cov

0 commit comments

Comments
 (0)