mirror of
https://github.com/aljazceru/mcp-python-sdk.git
synced 2025-12-19 06:54:18 +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
|
- name: Install uv
|
||||||
uses: astral-sh/setup-uv@v3
|
uses: astral-sh/setup-uv@v3
|
||||||
|
|
||||||
- name: "Set up Python"
|
|
||||||
uses: actions/setup-python@v5
|
|
||||||
with:
|
with:
|
||||||
python-version-file: ".python-version"
|
enable-cache: true
|
||||||
|
|
||||||
- name: Install the project
|
- name: Set up Python 3.12
|
||||||
run: uv sync --frozen --all-extras --dev
|
run: uv python install 3.12
|
||||||
|
|
||||||
- name: Build
|
- name: Build
|
||||||
run: uv build
|
run: uv build
|
||||||
|
|||||||
32
.github/workflows/shared.yml
vendored
32
.github/workflows/shared.yml
vendored
@@ -14,16 +14,11 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
enable-cache: true
|
enable-cache: true
|
||||||
|
|
||||||
- name: "Set up Python"
|
|
||||||
uses: actions/setup-python@v5
|
|
||||||
with:
|
|
||||||
python-version-file: ".python-version"
|
|
||||||
|
|
||||||
- name: Install the project
|
- 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
|
- name: Run ruff format check
|
||||||
run: uv run --frozen ruff check .
|
run: uv run --no-sync ruff check .
|
||||||
|
|
||||||
typecheck:
|
typecheck:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
@@ -35,19 +30,17 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
enable-cache: true
|
enable-cache: true
|
||||||
|
|
||||||
- name: "Set up Python"
|
|
||||||
uses: actions/setup-python@v5
|
|
||||||
with:
|
|
||||||
python-version-file: ".python-version"
|
|
||||||
|
|
||||||
- name: Install the project
|
- name: Install the project
|
||||||
run: uv sync --frozen --all-extras --dev
|
run: uv sync --frozen --all-extras --dev --python 3.12
|
||||||
|
|
||||||
- name: Run pyright
|
- name: Run pyright
|
||||||
run: uv run --frozen pyright
|
run: uv run --no-sync pyright
|
||||||
|
|
||||||
build:
|
test:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
python-version: ["3.10", "3.11", "3.12", "3.13"]
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
@@ -57,13 +50,8 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
enable-cache: true
|
enable-cache: true
|
||||||
|
|
||||||
- name: "Set up Python"
|
|
||||||
uses: actions/setup-python@v5
|
|
||||||
with:
|
|
||||||
python-version-file: ".python-version"
|
|
||||||
|
|
||||||
- name: Install the project
|
- 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
|
- 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