Skip to content

Commit

Permalink
Add the ruff INP001 rule (#2445)
Browse files Browse the repository at this point in the history
  • Loading branch information
JackEAllen authored Jan 8, 2025
2 parents 406b43a + 029d209 commit 6b22531
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
#2444: Ruff rule to check for missing __init__.py files
2 changes: 1 addition & 1 deletion environment-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ dependencies:
- pyinstaller==6.9.*
- pyright==1.1.*
- make==4.3
- ruff=0.3.3
- ruff=0.3.7
- pre-commit==3.5.*
- sphinx==7.2.*
- pydata-sphinx-theme==0.15.*
Expand Down
3 changes: 3 additions & 0 deletions mantidimaging/gui/widgets/palette_changer/test/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Copyright (C) 2021 ISIS Rutherford Appleton Laboratory UKRI
# SPDX - License - Identifier: GPL-3.0-or-later
from __future__ import annotations
5 changes: 4 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,13 @@ line-length = 120
target-version = "py310"

[tool.ruff.lint]
select = ["F", "E", "W", "UP", "B", "C4", "FA", "NPY"]
select = ["F", "E", "W", "UP", "B", "C4", "FA", "NPY", "INP"]
fixable = ["UP"]
ignore = ["UP014"]

[tool.ruff.lint.per-file-ignores]
"!mantidimaging/**.py" = ["INP"]

[tool.pyright]
typeCheckingMode = "basic"
reportMissingImports = false
Expand Down

0 comments on commit 6b22531

Please sign in to comment.