Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 8 additions & 9 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,17 +47,17 @@ jobs:
matrix:
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14"]
steps:
- uses: actions/cache@v4
- uses: actions/cache@v5
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/uv.lock') }}
restore-keys: |
${{ runner.os }}-pip-
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
- uses: actions/checkout@v6
- uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python-version }}
- uses: astral-sh/setup-uv@v6
- uses: astral-sh/setup-uv@v7
- name: Install ODBC driver
run: |
curl -sSL -O https://packages.microsoft.com/config/ubuntu/$(grep VERSION_ID /etc/os-release | cut -d '"' -f 2)/packages-microsoft-prod.deb
Expand All @@ -68,9 +68,9 @@ jobs:
run: make ci
- name: Test FastAPI/Blacksheep Example
run: |
PYTHONPATH=$DEST_FASTAPI uv run pytest $PYTEST_ARGS $DEST_FASTAPI/_tests.py
PYTHONPATH=$DEST_BLACKSHEEP uv run pytest $PYTEST_ARGS $DEST_BLACKSHEEP/_tests.py
PYTHONPATH=$DEST_SANIC uv run pytest $PYTEST_ARGS $DEST_SANIC/_tests.py
PYTHONPATH=$DEST_FASTAPI uv run --frozen pytest $PYTEST_ARGS $DEST_FASTAPI/_tests.py
PYTHONPATH=$DEST_BLACKSHEEP uv run --frozen pytest $PYTEST_ARGS $DEST_BLACKSHEEP/_tests.py
PYTHONPATH=$DEST_SANIC uv run --frozen pytest $PYTEST_ARGS $DEST_SANIC/_tests.py
env:
DEST_FASTAPI: examples/fastapi
DEST_BLACKSHEEP: examples/blacksheep
Expand All @@ -79,8 +79,7 @@ jobs:
PYTEST_ARGS: "-n auto --cov=tortoise --cov-append --cov-branch --tb=native -q"
- name: Upload Coverage
run: |
pip3 install --upgrade coveralls
coveralls --service=github
uvx coveralls --service=github
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COVERALLS_FLAG_NAME: ${{ matrix.python-version }}
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/codspeed.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@ jobs:
name: Run benchmarks
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
- uses: actions/checkout@v6
- uses: actions/setup-python@v6
with:
# 3.12 is the minimum required version for profiling enabled
python-version: "3.12"

- uses: astral-sh/setup-uv@v6
- uses: astral-sh/setup-uv@v7

- name: Build dists
run: make build
Expand All @@ -29,4 +29,4 @@ jobs:
uses: CodSpeedHQ/action@v3
with:
token: ${{ secrets.CODSPEED_TOKEN }}
run: uv run pytest tests/benchmarks --codspeed
run: uv run --frozen pytest tests/benchmarks --codspeed
6 changes: 3 additions & 3 deletions .github/workflows/gh-pages-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ jobs:
publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
- uses: actions/checkout@v6
- uses: actions/setup-python@v6
with:
python-version: "3.9"
- uses: astral-sh/setup-uv@v6
- uses: astral-sh/setup-uv@v7
- name: Build docs
run: make docs
- name: Deploy release docs
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/gh-pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ jobs:
publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
- uses: actions/checkout@v6
- uses: actions/setup-python@v6
with:
python-version: "3.9"
- uses: astral-sh/setup-uv@v6
- uses: astral-sh/setup-uv@v7
- name: Build docs
run: make docs
- name: Deploy latest docs
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/pypi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ jobs:
publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
- uses: actions/checkout@v6
- uses: actions/setup-python@v6
with:
python-version: '3.9'
- uses: astral-sh/setup-uv@v6
- uses: astral-sh/setup-uv@v7
- name: Build dists
run: make build
- name: Pypi Publish
Expand Down
3 changes: 2 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ classifiers = [
"Framework :: AsyncIO",
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: Database",
"Typing :: Typed",
"Operating System :: POSIX",
"Operating System :: MacOS :: MacOS X",
"Operating System :: Microsoft :: Windows",
Expand Down Expand Up @@ -120,7 +121,7 @@ build-backend = "pdm.backend"
version = {source="file", path="tortoise/__init__.py"}

[tool.pdm.build]
excludes = ["./**/.git", "./**/.*_cache"]
excludes = ["./**/.git", "./**/.*_cache", "examples"]
include = ["CHANGELOG.rst", "LICENSE", "README.rst"]

[tool.mypy]
Expand Down
Loading