Skip to content

Saleor Core: the high performance, composable, headless commerce API.

Improve tooling config, add automated isort check

Patryk Zawadzki2047737c2ff2
diff --git a/.codeclimate.yml b/.codeclimate.yml
index 33587369a7..9a2fad58c4 100644
--- a/.codeclimate.yml
+++ b/.codeclimate.yml
@@ -1,6 +1,9 @@
engines:
eslint:
enabled: true
+ isort:
+ enabled: true
+ channel: beta
pep8:
enabled: true
pylint:
@@ -10,10 +13,13 @@ engines:
config:
languages:
python:
- mass_threshold: 100
+ mass_threshold: 100
python_version: 3
exclude_patterns:
+- ".*"
+- "**/__pycache__/"
- "**/migrations/"
+- "node_modules/"
- "tests/"
- "**/test_*"
ratings:
diff --git a/.pylintrc b/.pylintrc
index 4c36c6986f..172c6b4730 100644
--- a/.pylintrc
+++ b/.pylintrc
@@ -1,8 +1,11 @@
[MASTER]
-load-plugins=pylint_django
+load-plugins=pylint.extensions.bad_builtin, pylint.extensions.mccabe, pylint_celery, pylint_django
[MESSAGES CONTROL]
-disable=C0103, C0111, I0011, W0621
+disable=C0103, C0111, C0412, I0011, R0903, W0621
+
+[DESIGN]
+max-complexity=5
[SIMILARITIES]
ignore-imports=yes
diff --git a/setup.cfg b/setup.cfg
index 1d9cf12f23..2354e629bb 100644
--- a/setup.cfg
+++ b/setup.cfg
@@ -24,7 +24,7 @@ exclude =
docs/,
node_modules/,
*/migrations/
-ignore = H101,H238,H301,H306
+ignore = H101,H238,H301,H306,W503
[pep8]
exclude =
@@ -33,10 +33,10 @@ exclude =
docs/,
node_modules/,
*/migrations/
-ignore = H101,H238,H301,H306
+ignore = H101,H238,H301,H306,W503
[pydocstyle]
-ignore = D100, D104, D105, D106, D107, D203, D213
+ignore = D100, D101, D102, D103, D104, D105, D106, D107, D203, D213
inherit = false
match-dir = (?!migrations)[^\.].*
@@ -48,3 +48,10 @@ skip =
docs
migrations
node_modules
+
+[yapf]
+based_on_style = pep8
+align_closing_bracket_with_visual_indent = false
+coalesce_brackets = true
+split_before_closing_bracket = false
+split_before_first_argument = true