Skip to content

Commit

Permalink
bump to py3.9, ruff
Browse files Browse the repository at this point in the history
  • Loading branch information
grizz committed Jan 20, 2024
1 parent 36f7f0f commit cd49d15
Show file tree
Hide file tree
Showing 6 changed files with 935 additions and 678 deletions.
17 changes: 8 additions & 9 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,36 +7,35 @@ jobs:
linting:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Install virtualenv from poetry
uses: 20c/workflows/poetry@v1
- name: Run linters
run: |
poetry run pre-commit run --all-files
poetry run pre-commit run --all-files
test:
needs: linting
strategy:
fail-fast: false
matrix:
os: [ "ubuntu-latest", "macos-latest" ]
python-version: [ "3.7", "3.8", "3.9", "3.10" ]
python-version: [ "3.9", "3.10", "3.11", "3.12" ]
runs-on: ${{ matrix.os }}
steps:
- name: Check out repository
uses: actions/checkout@v2
uses: actions/checkout@v4
- name: Install virtualenv from poetry
uses: 20c/workflows/poetry@v1
with:
python-version: ${{ matrix.python-version }}
- name: Run tests
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install tox-gh-actions
poetry run tox -e py
# upload coverage stats
pip install tox tox-gh-actions
- name: Run tests
run: tox -e py
- name: Upload coverage
uses: codecov/codecov-action@v3
with:
# file: ./coverage.xml
fail_ci_if_error: true
40 changes: 14 additions & 26 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,40 +1,28 @@
fail_fast: false
exclude: |
(?x)^(
tests/data/.*
)$
(?x)^(
tests/data/.*
)$
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v2.3.0
rev: v4.5.0
hooks:
- id: check-yaml
- id: trailing-whitespace
- repo: local
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version.
rev: v0.1.14
hooks:
- id: system
name: isort
entry: poetry run isort .
language: system
pass_filenames: false
# Run the linter.
- id: ruff
args: [--fix]
# Run the formatter.
- id: ruff-format
- repo: local
hooks:
- id: pyupgrade
- id: pyupgrade
name: pyupgrade
entry: poetry run pyupgrade --py37-plus
entry: poetry run pyupgrade --py39-plus
language: python
types: [python]
pass_filenames: true
- repo: local
hooks:
- id: system
name: Black
entry: poetry run black .
language: system
pass_filenames: false
- repo: local
hooks:
- id: system
name: flake8
entry: poetry run flake8 .
language: system
pass_filenames: false
8 changes: 6 additions & 2 deletions CHANGELOG.yaml
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
Unreleased:
added: []
added:
- python to 3.9
- ansible Templar templating system
- loopcontrol
- allow adding filters
changed: []
deprecated: []
fixed: []
removed:
- python 3.7 support
- python 3.7, 3.8 support
security: []

0.2.0:
Expand Down
Loading

0 comments on commit cd49d15

Please sign in to comment.