Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update CI #88

Merged
merged 2 commits into from
Jun 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,17 +30,17 @@ jobs:
- name: Lint with ruff
uses: chartboost/ruff-action@v1
with:
version: 0.4.1
version: 0.4.9
- name: Check formatting with ruff
uses: chartboost/ruff-action@v1
with:
version: 0.4.1
version: 0.4.9
args: format

- name: Typecheck with pyright
uses: jakebailey/pyright-action@v2
with:
version: 1.1.359
version: 1.1.367

- name: Thorough check with pylint
run: pylint pymend
Expand Down
4 changes: 2 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,15 +30,15 @@ repos:
- id: check-builtin-literals
language: python
- repo: "https://github.com/charliermarsh/ruff-pre-commit"
rev: v0.4.1
rev: v0.4.9
hooks:
- id: ruff
args:
- "--fix"
- "--exit-non-zero-on-fix"
- id: ruff-format
- repo: https://github.com/crate-ci/typos
rev: v1.20.9
rev: v1.22.7
hooks:
- id: typos
args: []
Expand Down
2 changes: 1 addition & 1 deletion pymend/file_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ def parse_from_ast(
nodes_of_interest: list[ElementDocstring] = []
try:
file_ast = ast.parse(self.file_content)
except Exception as exc: # noqa: BLE001
except Exception as exc:
msg = f"Failed to parse source file AST: {exc}\n"
raise AssertionError(msg) from exc
for node in ast.walk(file_ast):
Expand Down
2 changes: 1 addition & 1 deletion pymend/pymend.py
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,7 @@ def assert_equality(self, src_lines: str, dst_lines: str) -> None:
"""
try:
src_ast = ast.parse(src_lines)
except Exception as exc: # noqa: BLE001
except Exception as exc:
msg = f"Failed to parse source file AST: {exc}\n"
raise AssertionError(msg) from exc
try:
Expand Down
2 changes: 1 addition & 1 deletion pymend/types.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ def output_docstring(
self._escape_triple_quotes()
try:
parsed = dsp.parse(self.docstring, style=input_style)
except Exception as e: # noqa: BLE001
except Exception as e:
msg = f"Failed to parse docstring for `{self.name}` with error: `{e}`"
raise AssertionError(msg) from e
self._fix_docstring(parsed, settings)
Expand Down