Use poetry instead of setuptools/requirements #182
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Python Code Quality and Lint | |
on: | |
push: | |
branches: [ master ] | |
paths: | |
- 'wikibaseintegrator/**.py' | |
- 'test/**.py' | |
pull_request: | |
branches: [ '**' ] | |
paths: | |
- 'wikibaseintegrator/**.py' | |
- 'test/**.py' | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/[email protected] | |
- name: Set up Python 3.12 | |
uses: actions/[email protected] | |
with: | |
python-version: '3.12' | |
- name: Cache pip | |
uses: actions/cache@v3 | |
with: | |
path: ~/.cache/pip | |
key: ${{ runner.os }}-pip-${{ hashFiles('poetry.lock') }} | |
restore-keys: | | |
${{ runner.os }}-pip- | |
${{ runner.os }}- | |
- name: Upgrade setup tools | |
run: | | |
python -m pip install --upgrade poetry | |
- name: Install dependencies | |
run: | | |
python -m poetry install --with dev | |
- name: isort imports check | |
run: | | |
python -m poetry run isort --check --diff wikibaseintegrator test | |
- name: mypy typing check | |
run: | | |
python -m poetry run mypy --install-types --non-interactive | |
- name: pylint code linting | |
run: | | |
python -m poetry run pylint wikibaseintegrator test || pylint-exit $? | |
- name: codespell spell checking | |
run: | | |
python -m poetry run codespell wikibaseintegrator test | |
- name: flynt string formatter converting | |
run: | | |
python -m poetry run flynt -f wikibaseintegrator test |