Skip to content

Commit

Permalink
updated linters due to deprecation warning
Browse files Browse the repository at this point in the history
  • Loading branch information
KennethEnevoldsen committed Mar 19, 2024
1 parent 61d5e9c commit 98e6f97
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion makefile
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ lint:
@echo "--- 🧹 Running linters ---"
pyproject-parser check pyproject.toml # check pyproject.toml
ruff format . # running ruff formatting (.ipynb, .py)
ruff **/*.py --fix # running ruff linting (.py)
ruff check **/*.py --fix # running ruff linting (.py)

test:
@echo "--- 🧪 Running tests ---"
Expand Down
12 changes: 6 additions & 6 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ pythonPlatform = "Darwin"
[tool.ruff]
extend-include = ["*.ipynb"]
# Enable pycodestyle (`E`) and Pyflakes (`F`) codes by default.
select = [
lint.select = [
"A",
"ANN",
"ARG",
Expand Down Expand Up @@ -120,7 +120,7 @@ select = [
"SIM",
"W",
]
ignore = [
lint.ignore = [
"ANN101",
"ANN401",
"E402",
Expand All @@ -130,9 +130,9 @@ ignore = [
"RET504",
"COM812",
]
ignore-init-module-imports = true
lint.ignore-init-module-imports = true
# Allow autofix for all enabled rules (when `--fix`) is provided.
unfixable = ["ERA"]
lint.unfixable = ["ERA"]
# Exclude a variety of commonly ignored directories.
exclude = [
".bzr",
Expand All @@ -158,10 +158,10 @@ exclude = [
"docs/conf.py",
]
# Allow unused variables when underscore-prefixed.
dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$"
lint.dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$"
target-version = "py38"

[tool.ruff.flake8-annotations]
[tool.ruff.lint.flake8-annotations]
mypy-init-return = true
suppress-none-returning = true

Expand Down

0 comments on commit 98e6f97

Please sign in to comment.