mirror of
https://github.com/aljazceru/mcp-python-sdk.git
synced 2025-12-18 22:44:20 +01:00
ci: test multiple python versions (#345)
This commit is contained in:
committed by
GitHub
parent
fd2fd34357
commit
9ec6db201f
9
.github/workflows/publish-pypi.yml
vendored
9
.github/workflows/publish-pypi.yml
vendored
@@ -14,14 +14,11 @@ jobs:
|
||||
|
||||
- name: Install uv
|
||||
uses: astral-sh/setup-uv@v3
|
||||
|
||||
- name: "Set up Python"
|
||||
uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version-file: ".python-version"
|
||||
enable-cache: true
|
||||
|
||||
- name: Install the project
|
||||
run: uv sync --frozen --all-extras --dev
|
||||
- name: Set up Python 3.12
|
||||
run: uv python install 3.12
|
||||
|
||||
- name: Build
|
||||
run: uv build
|
||||
|
||||
32
.github/workflows/shared.yml
vendored
32
.github/workflows/shared.yml
vendored
@@ -14,16 +14,11 @@ jobs:
|
||||
with:
|
||||
enable-cache: true
|
||||
|
||||
- name: "Set up Python"
|
||||
uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version-file: ".python-version"
|
||||
|
||||
- name: Install the project
|
||||
run: uv sync --frozen --all-extras --dev
|
||||
run: uv sync --frozen --all-extras --dev --python 3.12
|
||||
|
||||
- name: Run ruff format check
|
||||
run: uv run --frozen ruff check .
|
||||
run: uv run --no-sync ruff check .
|
||||
|
||||
typecheck:
|
||||
runs-on: ubuntu-latest
|
||||
@@ -35,19 +30,17 @@ jobs:
|
||||
with:
|
||||
enable-cache: true
|
||||
|
||||
- name: "Set up Python"
|
||||
uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version-file: ".python-version"
|
||||
|
||||
- name: Install the project
|
||||
run: uv sync --frozen --all-extras --dev
|
||||
run: uv sync --frozen --all-extras --dev --python 3.12
|
||||
|
||||
- name: Run pyright
|
||||
run: uv run --frozen pyright
|
||||
run: uv run --no-sync pyright
|
||||
|
||||
build:
|
||||
test:
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
matrix:
|
||||
python-version: ["3.10", "3.11", "3.12", "3.13"]
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
@@ -57,13 +50,8 @@ jobs:
|
||||
with:
|
||||
enable-cache: true
|
||||
|
||||
- name: "Set up Python"
|
||||
uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version-file: ".python-version"
|
||||
|
||||
- name: Install the project
|
||||
run: uv sync --frozen --all-extras --dev
|
||||
run: uv sync --frozen --all-extras --dev --python ${{ matrix.python-version }}
|
||||
|
||||
- name: Run pytest
|
||||
run: uv run --frozen pytest
|
||||
run: uv run --no-sync pytest
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
3.10
|
||||
Reference in New Issue
Block a user