From 91309d9533a15f61347b122510ca3bdae2c1911f Mon Sep 17 00:00:00 2001 From: Etienne Trimaille Date: Mon, 13 May 2024 10:34:21 +0200 Subject: [PATCH] Try to use Ruff isort --- pyproject.toml | 44 +++++++++++++++++++++++++++++++++++++------- 1 file changed, 37 insertions(+), 7 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 7b71750f..9199be9f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -3,31 +3,61 @@ [tool.ruff] line-length = 120 -target-version = "py310" +target-version = "py37" exclude = [ ".venv", ".local", ".test/.local", + ".cache", ] [tool.ruff.format] indent-style = "space" [tool.ruff.lint] -extend-select = ["E", "F", "ANN", "W", "T", "COM", "RUF"] -ignore = ["ANN101", "ANN102", "ANN002", "ANN003", "RUF100"] +extend-select = [ + "E", + "F", + "ANN", + "W", + "T", + "COM", + "RUF", +] +ignore = [ + "ANN101", + "ANN102", + "ANN002", + "ANN003", + "RUF100", +] [tool.ruff.lint.per-file-ignores] -"tests/*" = ["T201", "E501"] -"test/*" = ["T201", "E501"] -"lizmap_server/tooltip.py" = ["RUF001", "RUF002"] +"tests/*" = [ + "T201", + "E501", +] +"test/*" = [ + "T201", + "E501", +] +"lizmap_server/tooltip.py" = [ + "RUF001", + "RUF002", +] [tool.ruff.lint.isort] -lines-between-types = 1 +#lines-between-types = 1 known-third-party = [ "qgis", ] +#combine-as-imports = true +#split-on-trailing-comma = true +#multi-line-output = 3 +#include-trailing-comma = true +#use-parentheses = true +#ensure-newline-before-comments = true [tool.ruff.lint.flake8-annotations] ignore-fully-untyped = true