Skip to content

Commit 634348e

Browse files
committed
Fix #148 - Errors found in Python isort
1 parent d16ab99 commit 634348e

File tree

5 files changed

+39
-8
lines changed

5 files changed

+39
-8
lines changed

.github/workflows/fetch-daily.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,8 @@ jobs:
1717
- name: Set up Python
1818
uses: actions/setup-python@v6
1919
with:
20-
python-version: '3.14'
20+
python-version: '3.15'
21+
architecture: 'x64'
2122

2223
- name: Install dependencies
2324
run: |

.github/workflows/pre-commit.yml

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,24 +11,29 @@ concurrency:
1111

1212
jobs:
1313
pre-commit:
14-
name: Run pre-commit # https://pre-commit.com/
14+
name: Run pre-commit
1515
runs-on: ubuntu-latest
1616
steps:
1717
- name: 'Checkout ${{ github.ref }} ( ${{ github.sha }} )'
1818
uses: actions/checkout@v6
19-
- uses: actions/setup-python@v6 # https://www.python.org/
19+
20+
- uses: actions/setup-python@v6
2021
with:
21-
python-version: '3.13' # Version range or exact version of a Python version to use, using SemVer's version range syntax
22-
architecture: 'x64' # optional x64 or x86. Defaults to x64 if not specified
23-
- name: Install dependencies # https://pip.pypa.io/en/stable/
22+
python-version: '3.15'
23+
architecture: 'x64'
24+
25+
- name: Install dependencies
2426
run: |
2527
python -m pip install --upgrade pip
2628
pip install pre-commit
29+
2730
- name: set PY
2831
run: echo "PY=$(python -VV | sha256sum | cut -d' ' -f1)" >> "$GITHUB_ENV"
32+
2933
- uses: actions/cache@v5
3034
with:
3135
path: ~/.cache/pre-commit
3236
key: pre-commit|${{ env.PY }}|${{ hashFiles('.pre-commit-config.yaml') }}
37+
3338
- name: Run pre-commit
3439
run: pre-commit run --color=always --all-files

.github/workflows/render-on-push.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,8 @@ jobs:
2626
- name: Set up Python
2727
uses: actions/setup-python@v6
2828
with:
29-
python-version: '3.12'
29+
python-version: '3.15'
30+
architecture: 'x64'
3031

3132
- name: Install dependencies
3233
run: |

.pre-commit-config.yaml

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,19 @@ repos:
2121
- id: forbid-submodules
2222
- id: mixed-line-ending
2323
- id: trailing-whitespace
24-
24+
- repo: https://github.com/pycqa/isort
25+
rev: 5.12.0
26+
hooks:
27+
- id: isort
28+
name: isort (python imports)
29+
language: python
30+
types: [python]
31+
files: \.(py)$
32+
- repo: https://github.com/psf/black
33+
rev: 23.11.0
34+
hooks:
35+
- id: black
36+
name: black (python formatter)
37+
language: python
38+
types: [python]
39+
files: \.(py)$

pyproject.toml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,15 @@ pylint = "*"
99
yamllint = "*"
1010
isort = "*"
1111

12+
[tool.black]
13+
line-length = 88
14+
target-version = ['py310', 'py311', 'py312', 'py313']
15+
skip-string-normalization = false
16+
include = '\.pyi?$'
17+
exclude = '''
18+
/(\.eggs|\.git|\.hg|\.mypy_cache|\.tox|\.venv|_build|buck-out|build|dist)/
19+
'''
20+
1221
[tool.isort]
1322
profile = "black"
1423
line_length = 88

0 commit comments

Comments
 (0)