diff --git a/pyproject.toml b/pyproject.toml index e5dc3d25c5..36581dbb3b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -63,21 +63,23 @@ select = [ # "FA", # future annotations "UP", # pyupgrade - "RUF015", # next() > list_comprehension[0] - "RUF022", # sort __all__ + "unnecessary-iterable-allocation-for-first-element", + "unsorted-dunder-all", "I", # import sorting "unused-noqa", + "rule-codes-in-selectors", ] ignore = [ - "FA100", # Conflicts with Blender using annotations for props definitions. + # Conflicts with Blender using annotations for props definitions. + "future-rewritable-type-annotation", # Maybe will enable later: - "UP007", # Union[X,Y] to X | Y - "UP045", # Optional to X | None - "UP015", # Unnecessary mode argument - "UP028", # yield for -> yield from - "UP030", # implicit references for positional format fields - "UP031", # Replace % with .format - "UP032", # Replace .format with f-string + "non-pep604-annotation-union", # Union[X,Y] to X | Y + "non-pep604-annotation-optional", # Optional to X | None + "redundant-open-modes", # Unnecessary mode argument + "yield-in-for-loop", # yield for -> yield from + "format-literals", # implicit references for positional format fields + "printf-string-formatting", # Replace % with .format + "f-string", # Replace .format with f-string ] [tool.ty.rules] diff --git a/src/bcf/pyproject.toml b/src/bcf/pyproject.toml index 958bd8abe1..b985ce8714 100644 --- a/src/bcf/pyproject.toml +++ b/src/bcf/pyproject.toml @@ -66,5 +66,5 @@ commands = pytest --cov --cov-report=term tests [tool.ruff] extend = "../../pyproject.toml" lint.extend-select = [ - "F401", # unused imports + "unused-import", # unused imports ] diff --git a/src/bonsai/pyproject.toml b/src/bonsai/pyproject.toml index 6d2fd45f19..052c2d14c4 100644 --- a/src/bonsai/pyproject.toml +++ b/src/bonsai/pyproject.toml @@ -33,7 +33,7 @@ exclude = ["test*"] [tool.ruff] extend = "../../pyproject.toml" lint.extend-select = [ - "F401", # unused imports + "unused-import", # unused imports ] [tool.ruff.lint.isort] diff --git a/src/bonsai/test/pyproject.toml b/src/bonsai/test/pyproject.toml index 7567fe8627..94421e55b4 100644 --- a/src/bonsai/test/pyproject.toml +++ b/src/bonsai/test/pyproject.toml @@ -1,5 +1,5 @@ [tool.ruff] extend = "../pyproject.toml" lint.ignore = [ - "F401", # unused imports + "unused-import", # unused imports ] diff --git a/src/bsdd/pyproject.toml b/src/bsdd/pyproject.toml index 1bc1a04f2d..285b869791 100644 --- a/src/bsdd/pyproject.toml +++ b/src/bsdd/pyproject.toml @@ -47,5 +47,5 @@ py-modules = ["bsdd","bsdd_json","type_hints"] [tool.ruff] extend = "../../pyproject.toml" lint.extend-select = [ - "F401", # unused imports + "unused-import", # unused imports ] diff --git a/src/ifc4d/pyproject.toml b/src/ifc4d/pyproject.toml index c061448fd4..b5f2ebd0a0 100644 --- a/src/ifc4d/pyproject.toml +++ b/src/ifc4d/pyproject.toml @@ -32,5 +32,5 @@ exclude = ["test*"] [tool.ruff] extend = "../../pyproject.toml" lint.extend-select = [ - "F401", # unused imports + "unused-import", # unused imports ] diff --git a/src/ifc5d/pyproject.toml b/src/ifc5d/pyproject.toml index 11af93b0e2..bb1775efd6 100644 --- a/src/ifc5d/pyproject.toml +++ b/src/ifc5d/pyproject.toml @@ -44,5 +44,5 @@ exclude = ["test*"] [tool.ruff] extend = "../../pyproject.toml" lint.extend-select = [ - "F401", # unused imports + "unused-import", # unused imports ] diff --git a/src/ifccsv/pyproject.toml b/src/ifccsv/pyproject.toml index de53241063..db7740bb88 100644 --- a/src/ifccsv/pyproject.toml +++ b/src/ifccsv/pyproject.toml @@ -30,5 +30,5 @@ py-modules = ["ifccsv"] [tool.ruff] extend = "../../pyproject.toml" lint.extend-select = [ - "F401", # unused imports + "unused-import", # unused imports ] diff --git a/src/ifcopenshell-python/pyproject.toml b/src/ifcopenshell-python/pyproject.toml index 93564d4042..752d4ad48d 100644 --- a/src/ifcopenshell-python/pyproject.toml +++ b/src/ifcopenshell-python/pyproject.toml @@ -49,5 +49,5 @@ include = ["ifcopenshell*"] [tool.ruff] extend = "../../pyproject.toml" lint.extend-select = [ - "F401", # unused imports + "unused-import", # unused imports ] diff --git a/src/ifcpatch/pyproject.toml b/src/ifcpatch/pyproject.toml index 4d36bc2945..9f56e24171 100644 --- a/src/ifcpatch/pyproject.toml +++ b/src/ifcpatch/pyproject.toml @@ -37,5 +37,5 @@ extend = "../../pyproject.toml" [tool.ruff.lint] extend-select = [ - "F401", # unused imports + "unused-import", # unused imports ] diff --git a/src/ifcsverchok/pyproject.toml b/src/ifcsverchok/pyproject.toml index 4c8f1dfde2..d3022f3e76 100644 --- a/src/ifcsverchok/pyproject.toml +++ b/src/ifcsverchok/pyproject.toml @@ -1,5 +1,5 @@ [tool.ruff] extend = "../../pyproject.toml" lint.extend-select = [ - "F401", # unused imports + "unused-import", # unused imports ] diff --git a/src/ifctester/pyproject.toml b/src/ifctester/pyproject.toml index 52ba812349..bbcc6a68c2 100644 --- a/src/ifctester/pyproject.toml +++ b/src/ifctester/pyproject.toml @@ -46,5 +46,5 @@ exclude = ["test*"] [tool.ruff] extend = "../../pyproject.toml" lint.extend-select = [ - "F401", # unused imports + "unused-import", # unused imports ]