Skip to content

Commit 73f2fca

Browse files
authored
Update CI, require Python 3.9+ and up-to-date Django (#63)
1 parent 15fdf70 commit 73f2fca

File tree

3 files changed

+26
-39
lines changed

3 files changed

+26
-39
lines changed

.github/workflows/ci.yml

Lines changed: 18 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -10,41 +10,31 @@ jobs:
1010
Lint:
1111
runs-on: ubuntu-latest
1212
steps:
13-
- uses: actions/checkout@v3
14-
- uses: actions/setup-python@v4
15-
with:
16-
python-version: "3.11"
17-
- uses: pre-commit/action@v3.0.0
13+
- uses: actions/checkout@v4
14+
- uses: akx/pre-commit-uv-action@v0.1.0
1815
Python:
1916
runs-on: ubuntu-latest
2017
env:
2118
DEBUG: "1"
2219
strategy:
2320
matrix:
2421
include:
25-
- python-version: "3.7"
26-
- python-version: "3.11"
22+
- python-version: "3.9"
23+
- python-version: "3.13"
2724
steps:
28-
- uses: actions/checkout@v3
29-
- name: "Set up Python ${{ matrix.python-version }}"
30-
uses: actions/setup-python@v4
25+
- uses: actions/checkout@v4
26+
- uses: astral-sh/setup-uv@v6
3127
with:
3228
python-version: "${{ matrix.python-version }}"
33-
cache: pip
34-
cache-dependency-path: |
35-
pyproject.toml
36-
setup.py
37-
tox.ini
38-
- run: pip install -U tox tox-gh-actions
39-
- run: tox
40-
- uses: codecov/codecov-action@v3
29+
- run: uvx --with=tox-gh-actions --with=tox-uv tox
30+
- uses: codecov/codecov-action@v5
4131
JavaScript:
4232
runs-on: ubuntu-latest
4333
steps:
44-
- uses: actions/checkout@v3
45-
- uses: actions/setup-node@v3
34+
- uses: actions/checkout@v4
35+
- uses: actions/setup-node@v4
4636
with:
47-
node-version: 18.x
37+
node-version: 22.x
4838
cache: yarn
4939
cache-dependency-path: |
5040
infotv/frontend/package.json
@@ -57,7 +47,7 @@ jobs:
5747
working-directory: ./infotv/frontend
5848
- run: yarn test
5949
working-directory: ./infotv/frontend
60-
- uses: actions/upload-artifact@v3
50+
- uses: actions/upload-artifact@v4
6151
with:
6252
name: infotv-static
6353
path: ./infotv/static
@@ -67,19 +57,17 @@ jobs:
6757
- JavaScript
6858
runs-on: ubuntu-latest
6959
steps:
70-
- uses: actions/checkout@v3
71-
- uses: actions/setup-python@v4
60+
- uses: actions/checkout@v4
61+
- uses: astral-sh/setup-uv@v6
7262
with:
73-
python-version: "3.11"
74-
cache: pip
75-
- uses: actions/download-artifact@v2
63+
python-version: "3.13"
64+
- uses: actions/download-artifact@v4
7665
with:
7766
name: infotv-static
7867
path: infotv/static
79-
- run: pip install build
80-
- run: python -m build .
68+
- run: uv build .
8169
- run: zipinfo dist/*.whl | grep static/infotv/bundle.js || exit 42
82-
- uses: actions/upload-artifact@v3
70+
- uses: actions/upload-artifact@v4
8371
with:
8472
name: dist
8573
path: dist

pyproject.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ dynamic = ["version"]
88
description = "A television, with information"
99
readme = "README.md"
1010
license = "MIT"
11-
requires-python = ">=3.7"
11+
requires-python = ">=3.9"
1212
authors = [
1313
{ name = "Kehittyvien conien Suomi ry" },
1414
{ name = "Aarni Koskela", email = "akx@iki.fi" },
@@ -18,7 +18,7 @@ classifiers = [
1818
"License :: OSI Approved :: MIT License",
1919
]
2020
dependencies = [
21-
"Django>=3.2",
21+
"Django>=4.2",
2222
"jsonfield>=1.0.3",
2323
"requests>=2.13.0",
2424
]

tox.ini

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
[tox]
22
envlist =
3-
py37-django32
4-
py3{8,9,10,11}-django{40,41,42}
3+
py3{9,10,11}-django{42}
4+
py3{10,11,12,13}-django{42,50,52}
55

66
[gh-actions]
77
python =
8-
3.7: py37
9-
3.8: py38
108
3.9: py39
119
3.10: py310
1210
3.11: py311
11+
3.12: py312
12+
3.13: py313
1313

1414
[testenv]
1515
commands = py.test -ra -vvv --cov
@@ -18,7 +18,6 @@ env =
1818
deps =
1919
pytest-cov
2020
pytest-django
21-
django32: Django~=3.2.0
22-
django40: Django~=4.0.0
23-
django41: Django~=4.1.0
2421
django42: Django~=4.2.0
22+
django50: Django~=5.0.0
23+
django52: Django~=5.2.0

0 commit comments

Comments
 (0)