Skip to content

Commit 3aebe42

Browse files
committed
Use uv and test 3.13 and 3.12
1 parent 3e2dff0 commit 3aebe42

File tree

3 files changed

+194
-15
lines changed

3 files changed

+194
-15
lines changed

.github/workflows/ci.yml

Lines changed: 11 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,9 @@ jobs:
1313
with:
1414
fetch-depth: 0
1515
- uses: actions/setup-dotnet@v1
16-
- uses: actions/setup-python@v4
17-
- name: Install dependencies
18-
run: |
19-
python -m pip install --upgrade pip
20-
pip install build
16+
- uses: actions/setup-uv@v4
2117
- name: Build
22-
run: python -m build
18+
run: uv build
2319
- name: Upload source distribution
2420
uses: actions/upload-artifact@v3
2521
with:
@@ -34,8 +30,9 @@ jobs:
3430
with:
3531
fetch-depths: 0
3632
- uses: actions/setup-python@v4
33+
- uses: actions/setup-uv@v4
3734
- name: Install Ruff
38-
run: pip install ruff
35+
run: uv tool install ruff
3936
- name: Check format
4037
run: ruff format --check
4138
- name: Check lints
@@ -46,8 +43,8 @@ jobs:
4643
needs: build
4744
strategy:
4845
matrix:
49-
os: [ubuntu-latest, windows-latest, macos-latest]
50-
python: ['3.11', '3.10', '3.9', '3.8'] # pypy3
46+
os: [ubuntu-22.04, windows-latest, macos-latest]
47+
python: ['3.13', '3.12', '3.11', '3.10', '3.9', '3.8'] # pypy3
5148

5249
steps:
5350
- uses: actions/checkout@v3
@@ -58,7 +55,7 @@ jobs:
5855
dotnet-version: '6.0.x'
5956

6057
- name: Set up Python ${{ matrix.python }}
61-
uses: actions/setup-python@v4
58+
uses: actions/setup-uv@v4
6259
with:
6360
python-version: ${{ matrix.python }}
6461

@@ -76,8 +73,8 @@ jobs:
7673
7774
- name: Install dependencies
7875
run: |
79-
python -m pip install --upgrade pip
80-
pip install pytest
76+
uv venv
77+
uv pip install pytest
8178
8279
- name: Download wheel
8380
uses: actions/download-artifact@v3
@@ -88,11 +85,11 @@ jobs:
8885
- name: Install wheel
8986
shell: bash
9087
run: |
91-
pip install dist/*.whl
88+
uv pip install dist/*.whl
9289
9390
- name: Test with pytest
9491
run: |
95-
pytest
92+
uv run pytest
9693
9794
deploy:
9895
runs-on: ubuntu-latest

pyproject.toml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,10 @@ requires-python = ">=3.7"
1010

1111
readme = "README.md"
1212

13-
dependencies = ["cffi>=1.13"]
13+
dependencies = [
14+
"cffi >= 1.13; python_version <= '3.8'",
15+
"cffi >= 1.17; python_version >= '3.8'",
16+
]
1417

1518
classifiers = [
1619
"Development Status :: 4 - Beta",
@@ -32,6 +35,11 @@ email = "[email protected]"
3235
Sources = "https://github.com/pythonnet/clr-loader"
3336
Documentation = "https://pythonnet.github.io/clr-loader/"
3437

38+
[optional-dependencies]
39+
dev = [
40+
"pytest"
41+
]
42+
3543
[tool.setuptools]
3644
zip-safe = false
3745
package-data = {"clr_loader.ffi" = ["dlls/x86/*.dll", "dlls/amd64/*.dll"]}

0 commit comments

Comments
 (0)