Skip to content

Commit

Permalink
mypy action - uv
Browse files Browse the repository at this point in the history
  • Loading branch information
ADBond committed Sep 12, 2024
1 parent 2b36cda commit d029add
Showing 1 changed file with 11 additions and 29 deletions.
40 changes: 11 additions & 29 deletions .github/workflows/type-hinting.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,37 +15,19 @@ jobs:

- name: Check out repository
uses: actions/checkout@v3
- name: Set up python
id: setup-python
uses: actions/setup-python@v4
with:
python-version: 3.9.10

- name: Load cached Poetry installation
uses: actions/cache@v2
with:
path: ~/.local
key: poetry-0
- name: Install Poetry
uses: snok/install-poetry@v1
with:
version: 1.8.2
virtualenvs-create: true
virtualenvs-in-project: true
installer-parallel: true
- name: Load cached venv
id: cached-poetry-dependencies
uses: actions/cache@v2
- name: Setup uv
id: setup-uv
uses: astral-sh/setup-uv@v2
with:
path: .venv
key: venv-typehint-${{ runner.os }}-${{ steps.setup-python.outputs.python-version }}-${{ hashFiles('**/poetry.lock') }}-00
enable-cache: true
cache-dependency-glob: "uv.lock"

- name: Install Python 3.9.10
run: uv python install 3.9.10

- name: Install dependencies
if: steps.cached-poetry-dependencies.outputs.cache-hit != 'true'
run: poetry install --no-interaction --no-root
- name: Install library
run: poetry install --no-interaction
run: uv sync -p 3.9.10

- name: Run mypy
run: |
source .venv/bin/activate
mypy splinkclickhouse
run: uv run python -m mypy splinkclickhouse

0 comments on commit d029add

Please sign in to comment.