How to ignore Pyflakes errors ‘imported but unused’ in ‘__init__.py’ files?

To ignore all errors F401 (‘imported but unused’) in ‘__init__.py’ files, the option ‘per-file-ignores’ which has been available since version 3.7.0 of Flake8 (a better Pyflakes) is very convenient. It can be used on the command-line:

flake8 --per-file-ignores="__init__.py:F401" .

or in a configuration file (‘.flake8’, ‘setup.cfg’ or ‘tox.ini’):

[flake8]
per-file-ignores = __init__.py:F401

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)