Skip to content

Commit

Permalink
infra: update to 3.12
Browse files Browse the repository at this point in the history
  • Loading branch information
adhtruong committed Jan 17, 2024
1 parent d87e73d commit bb2b60d
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 13 deletions.
15 changes: 8 additions & 7 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@ jobs:
- uses: actions/checkout@v4

- uses: actions/setup-python@v5
id: python-setup
with:
python-version: "3.11"
python-version: "3.12"

- name: Install Pre-Commit
run: python -m pip install pre-commit && pre-commit install
Expand All @@ -24,7 +25,7 @@ jobs:
uses: actions/cache@v3
with:
path: ~/.cache/pre-commit/
key: pre-commit|${{ env.pythonLocation }}|${{ hashFiles('.pre-commit-config.yaml') }}
key: pre-commit|${{ env.pythonLocation }}|${{ steps.python-setup.outputs.python-version }}|${{ hashFiles('.pre-commit-config.yaml') }}

- name: Execute Pre-Commit
run: pre-commit run --show-diff-on-failure --color=always --all-files
Expand Down Expand Up @@ -78,15 +79,15 @@ jobs:
run: echo "PYTHONPATH=$PWD" >> $GITHUB_ENV

- name: Test
if: matrix.python-version != '3.11' || matrix.pydantic-version != '2.0' || matrix.sqla-version != '2'
if: matrix.python-version != '3.12' || matrix.pydantic-version != '2.0' || matrix.sqla-version != '2'
run: pdm run pytest tests

- name: Test with Coverage
if: matrix.python-version == '3.11' && matrix.pydantic-version == '2.0' && matrix.sqla-version == '2'
if: matrix.python-version == '3.12' && matrix.pydantic-version == '2.0' && matrix.sqla-version == '2'
run: pdm run pytest tests docs/examples --cov=. --cov-report=xml

- uses: actions/upload-artifact@v4
if: matrix.python-version == '3.11'
if: matrix.python-version == '3.12'
with:
name: coverage-xml
path: coverage.xml
Expand All @@ -103,12 +104,12 @@ jobs:
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.11"
python-version: "3.12"

- uses: pdm-project/setup-pdm@v3
name: Set up PDM
with:
python-version: "3.11"
python-version: "3.12"
allow-python-prereleases: true
cache: true

Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/docs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@ jobs:

- uses: actions/setup-python@v5
with:
python-version: "3.11"
python-version: "3.12"

- uses: pdm-project/setup-pdm@v3
name: Set up PDM
with:
python-version: "3.11"
python-version: "3.12"
allow-python-prereleases: true
cache: true

Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,12 @@ jobs:

- uses: actions/setup-python@v5
with:
python-version: "3.11"
python-version: "3.12"

- uses: pdm-project/setup-pdm@v3
name: Set up PDM
with:
python-version: "3.11"
python-version: "3.12"
allow-python-prereleases: true
cache: true

Expand All @@ -42,12 +42,12 @@ jobs:

- uses: actions/setup-python@v5
with:
python-version: "3.11"
python-version: "3.12"

- uses: pdm-project/setup-pdm@v3
name: Set up PDM
with:
python-version: "3.11"
python-version: "3.12"
allow-python-prereleases: true
cache: true

Expand Down
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ classifiers = [
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python",
"Topic :: Software Development :: Libraries",
"Topic :: Software Development :: Testing :: Unit",
Expand Down

0 comments on commit bb2b60d

Please sign in to comment.