Skip to content

Commit 84f7e67

Browse files
committed
Update actions file
1 parent d0d1253 commit 84f7e67

4 files changed

Lines changed: 82 additions & 16 deletions

File tree

‎.github/workflows/python-app.yml‎

Lines changed: 16 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -19,21 +19,23 @@ jobs:
1919

2020
steps:
2121
- uses: actions/checkout@v4
22-
- name: Set up Python 3.10
22+
23+
- name: Set up Python 3.11
2324
uses: actions/setup-python@v3
2425
with:
25-
python-version: "3.10"
26+
python-version: "3.11"
27+
28+
- name: Install Poetry
29+
uses: snok/install-poetry@v1
30+
2631
- name: Install dependencies
27-
run: |
28-
python -m pip install --upgrade pip
29-
pip install flake8 pytest
30-
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
31-
- name: Lint with flake8
32-
run: |
33-
# stop the build if there are Python syntax errors or undefined names
34-
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
35-
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
36-
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
32+
run: poetry install
33+
34+
- name: Lint with ruff
35+
run: poetry run ruff check . --format github
36+
37+
- name: Type check with Pyright
38+
run: pyright
39+
3740
- name: Test with pytest
38-
run: |
39-
pytest
41+
run: pytest

‎poetry.lock‎

Lines changed: 63 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎pyproject.toml‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@ pygments = "^2.19.2"
1919
pymdown-extensions = "^10.16.1"
2020
flask = "^3.1.2"
2121
pydantic = "^2.11.9"
22+
pyright = "^1.1.405"
23+
ruff = "^0.13.1"
2224

2325
[build-system]
2426
requires = ["poetry-core"]

‎scripts/build_html.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ def generate_codehilite_css():
3838

3939

4040
def generate_index_html(files: list[Path], output_dir: Path, style: str):
41-
print(f"Generating index file...")
41+
print("Generating index file...")
4242
links = "\n".join(
4343
f'<li><a href="{file.parent.name}/{file.name}">{file.name}</a></li>'
4444
for file in files

0 commit comments

Comments
 (0)