Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pylint ignore switch doesn't seem to work properly with pylint-django #247

Open
snake-soft opened this issue Oct 14, 2019 · 0 comments
Open

Comments

@snake-soft
Copy link

My Django projects directory structure is:
.
├── config
├── element
├── home
├── static
├── templates
├── tree
└── user

I wanted to use the following pylint command:
pylint --load-plugins=pylint_django --ignore=static,templates */
Result with errors:

************* Module static/__init__.py
static/__init__.py:1:0: F0001: No module named static/__init__.py (fatal)
************* Module templates/__init__.py
templates/__init__.py:1:0: F0001: No module named templates/__init__.py (fatal)

--------------------------------------------------------------------
Your code has been rated at 10.00/10 (previous run: 10.00/10, +0.00)

When i run
pylint --ignore=static,templates */
The result is (shortened):

************* Module element.migrations.0001_initial
...
************* Module home.views
...
************* Module element.migrations.0002_auto_20191013_0932
...
************* Module tree.models
...                                                 
************* Module tree.migrations.0002_tree_owner                                                                               
...
************* Module tree.migrations.0003_auto_20191013_1053
...
************* Module tree.migrations.0001_initial
...
************* Module user.migrations.0001_initial
...
------------------------------------------------------------------
Your code has been rated at 7.57/10 (previous run: 7.57/10, +0.00)

As you can see, if i use 'pylint_django'-plugin, the result gives an error for the missing init.py inside the ignored directories. It seems like it recognized to ignore these directories because the score gets a 10, but it tries to find the init.py and show an error if missing.

I don't think that is the right behavior.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant