Skip to content

Commit

Permalink
Use uv and test 3.13 and 3.12
Browse files Browse the repository at this point in the history
  • Loading branch information
filmor committed Dec 12, 2024
1 parent 3e2dff0 commit 3aebe42
Show file tree
Hide file tree
Showing 3 changed files with 194 additions and 15 deletions.
25 changes: 11 additions & 14 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,9 @@ jobs:
with:
fetch-depth: 0
- uses: actions/setup-dotnet@v1
- uses: actions/setup-python@v4
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install build
- uses: actions/setup-uv@v4
- name: Build
run: python -m build
run: uv build
- name: Upload source distribution
uses: actions/upload-artifact@v3
with:
Expand All @@ -34,8 +30,9 @@ jobs:
with:
fetch-depths: 0
- uses: actions/setup-python@v4
- uses: actions/setup-uv@v4
- name: Install Ruff
run: pip install ruff
run: uv tool install ruff
- name: Check format
run: ruff format --check
- name: Check lints
Expand All @@ -46,8 +43,8 @@ jobs:
needs: build
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
python: ['3.11', '3.10', '3.9', '3.8'] # pypy3
os: [ubuntu-22.04, windows-latest, macos-latest]
python: ['3.13', '3.12', '3.11', '3.10', '3.9', '3.8'] # pypy3

steps:
- uses: actions/checkout@v3
Expand All @@ -58,7 +55,7 @@ jobs:
dotnet-version: '6.0.x'

- name: Set up Python ${{ matrix.python }}
uses: actions/setup-python@v4
uses: actions/setup-uv@v4
with:
python-version: ${{ matrix.python }}

Expand All @@ -76,8 +73,8 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pytest
uv venv
uv pip install pytest
- name: Download wheel
uses: actions/download-artifact@v3
Expand All @@ -88,11 +85,11 @@ jobs:
- name: Install wheel
shell: bash
run: |
pip install dist/*.whl
uv pip install dist/*.whl
- name: Test with pytest
run: |
pytest
uv run pytest
deploy:
runs-on: ubuntu-latest
Expand Down
10 changes: 9 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,10 @@ requires-python = ">=3.7"

readme = "README.md"

dependencies = ["cffi>=1.13"]
dependencies = [
"cffi >= 1.13; python_version <= '3.8'",
"cffi >= 1.17; python_version >= '3.8'",
]

classifiers = [
"Development Status :: 4 - Beta",
Expand All @@ -32,6 +35,11 @@ email = "filmor@gmail.com"
Sources = "https://github.com/pythonnet/clr-loader"
Documentation = "https://pythonnet.github.io/clr-loader/"

[optional-dependencies]
dev = [
"pytest"
]

[tool.setuptools]
zip-safe = false
package-data = {"clr_loader.ffi" = ["dlls/x86/*.dll", "dlls/amd64/*.dll"]}
Expand Down
Loading

0 comments on commit 3aebe42

Please sign in to comment.