Browse Source

Updated flake8 config.

Rafał Pitoń 11 years ago
parent
commit
d8b2e71a29

+ 1 - 1
misago/conf/__init__.py

@@ -1 +1 @@
-from misago.conf.gateway import settings, db_settings
+from misago.conf.gateway import settings, db_settings  # noqa

+ 1 - 1
misago/core/forms.py

@@ -1,4 +1,4 @@
-from floppyforms import *
+from floppyforms import *  # noqa
 from floppyforms import Form as BaseForm, ModelForm as BaseModelForm
 
 

+ 1 - 1
misago/core/shortcuts.py

@@ -1,4 +1,4 @@
-from django.shortcuts import *
+from django.shortcuts import *  # noqa
 
 
 def paginate(object_list, page, per_page, orphans=0,

+ 1 - 0
misago/users/models/__init__.py

@@ -1 +1,2 @@
+# flake8: noqa
 from misago.users.models.usermodel import User

+ 0 - 1
misago/users/tests/test_validators.py

@@ -5,7 +5,6 @@ from django.test import TestCase
 from misago.conf import settings
 from misago.users.validators import (validate_email, validate_email_available,
                                      validate_password,
-                                     validate_password_complexity,
                                      validate_password_length,
                                      _validate_password_alphanumerics,
                                      _validate_password_case,

+ 2 - 0
misago/users/validators.py

@@ -96,6 +96,8 @@ def _validate_password_case(value):
 
 
 ALPHANUMERICS_RE = re.compile('[\W_]+', re.UNICODE)
+
+
 def _validate_password_special(value):
     alphanumerics_len = len(ALPHANUMERICS_RE.sub('', value))
 

+ 23 - 0
report.txt

@@ -0,0 +1,23 @@
+./misago/urls.py:1:1: F401 'include' imported but unused
+./misago/urls.py:5:5: E128 continuation line under-indented for visual indent
+./misago/conf/tests/test_migrationutils.py:13:80: E501 line too long (90 > 79 characters)
+./misago/conf/tests/test_migrationutils.py:14:80: E501 line too long (90 > 79 characters)
+./misago/conf/tests/test_migrationutils.py:15:80: E501 line too long (97 > 79 characters)
+./misago/users/management/commands/mcreatesuperuser.py:3:1: F401 'ValidationError' imported but unused
+./misago/users/management/commands/mcreatesuperuser.py:4:1: F401 'CommandError' imported but unused
+./misago/users/management/commands/mcreatesuperuser.py:6:1: F401 'force_str' imported but unused
+./misago/users/management/commands/mcreatesuperuser.py:7:1: F401 'input' imported but unused
+./misago/users/management/commands/mcreatesuperuser.py:22:17: E128 continuation line under-indented for visual indent
+./misago/users/management/commands/mcreatesuperuser.py:24:17: E128 continuation line under-indented for visual indent
+./misago/users/management/commands/mcreatesuperuser.py:26:17: E128 continuation line under-indented for visual indent
+./misago/users/management/commands/mcreatesuperuser.py:27:80: E501 line too long (92 > 79 characters)
+./misago/users/management/commands/mcreatesuperuser.py:28:17: E128 continuation line under-indented for visual indent
+./misago/users/management/commands/mcreatesuperuser.py:28:80: E501 line too long (82 > 79 characters)
+./misago/users/management/commands/mcreatesuperuser.py:29:21: E128 continuation line under-indented for visual indent
+./misago/users/management/commands/mcreatesuperuser.py:29:80: E501 line too long (87 > 79 characters)
+./misago/users/management/commands/mcreatesuperuser.py:30:80: E501 line too long (87 > 79 characters)
+./misago/users/management/commands/mcreatesuperuser.py:31:80: E501 line too long (86 > 79 characters)
+./misago/users/management/commands/mcreatesuperuser.py:33:17: E128 continuation line under-indented for visual indent
+./misago/users/management/commands/mcreatesuperuser.py:33:80: E501 line too long (103 > 79 characters)
+./misago/users/management/commands/mcreatesuperuser.py:37:9: F841 local variable 'User' is assigned to but never used
+./misago/users/management/commands/mcreatesuperuser.py:57:17: F821 undefined name 'sys'

+ 1 - 1
tox.ini

@@ -1,4 +1,4 @@
 [flake8]
 max-line-length = 79
-exclude = ./tests/*,./docs/*,./futuredep/*,./dev-manage/*,./testproject/*
+exclude = ./tests/*,./docs/*,./futuredep/*,./dev-manage/*,./testproject/*,./misago/conf/migrations/*,./misago/core/migrations/*,./misago/users/migrations/*,./misago/project_template/*,./misago/core/tests/test_migrationutils.py,./misago/core/testproject/*
 max-complexity = 12