Skip to content

Commit

Permalink
use pylint-django plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
SKairinos committed Dec 7, 2023
1 parent 84cee42 commit 64cb2e7
Show file tree
Hide file tree
Showing 4 changed files with 28 additions and 2 deletions.
8 changes: 7 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,14 @@
"--config",
"pyproject.toml"
],
"pylint.path": [
".venv/bin/python",
"-m",
"pylint"
],
"pylint.args": [
"--rcfile=pyproject.toml"
"--rcfile=pyproject.toml",
"--load-plugins=pylint_django"
],
"python.testing.pytestArgs": [
"-c=pyproject.toml",
Expand Down
1 change: 1 addition & 0 deletions Pipfile
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ mypy = "==1.6.1"
django-stubs = {version = "==4.2.6", extras = ["compatible-mypy"]}
djangorestframework-stubs = {version = "==3.14.4", extras = ["compatible-mypy"]}
pylint = "==3.0.2"
pylint-django = "==2.5.5"

[requires]
python_version = "3.8"
18 changes: 17 additions & 1 deletion Pipfile.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,5 +18,8 @@ plugins = ["mypy_django_plugin.main", "mypy_drf_plugin.main"]
[tool.django-stubs]
django_settings_module = "manage"

[tool.pylint.main]
init-hook = "import os; os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'manage')"

[tool.pylint.format]
max-line-length = 80

0 comments on commit 64cb2e7

Please sign in to comment.