Skip to content

Commit b99f53e

Browse files
imomalievatodorov
authored andcommitted
code cleanup and improvements after suggestions
1 parent 7b44aa1 commit b99f53e

File tree

4 files changed

+3
-4
lines changed

4 files changed

+3
-4
lines changed

CHANGELOG.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Changelog
44
Version 2.0.9 (dev)
55
-----------------------------
66

7-
- Fix ``UnboundLocalError: local variable 'key_cls' referenced before assignment`` for FK when using ``to`` as string pointing to model when models is a package
7+
- Fix ``UnboundLocalError: local variable 'key_cls' referenced before assignment`` for cases when models is a python package, the ``to`` argument is a string that is used in this pattern ``app.Model`` and also there is some other ``bool`` const like ``null=True`` right after ``to``. (Sardorbek Imomaliev)
88

99
Version 2.0.8 (18 April 2019)
1010
-----------------------------

pylint_django/tests/input/models/func_noerror_foreign_key_key_cls_unbound.py renamed to pylint_django/tests/input/func_noerror_foreign_key_key_cls_unbound.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
Checks that Pylint does not complain about ForeignKey pointing to model
33
in module of models package
44
"""
5-
# pylint: disable=missing-docstring,wrong-import-position
5+
# pylint: disable=missing-docstring
66
from django.db import models
77

88

pylint_django/tests/input/models/func_noerror_foreign_key_package.py renamed to pylint_django/tests/input/func_noerror_foreign_key_package.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
Checks that Pylint does not complain about ForeignKey pointing to model
33
in module of models package
44
"""
5-
# pylint: disable=missing-docstring,wrong-import-position
5+
# pylint: disable=missing-docstring
66
from django.db import models
77

88

pylint_django/tests/test_func.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,6 @@ def _file_name(test):
5656

5757

5858
TESTS = get_tests()
59-
TESTS.extend(get_tests('input/models'))
6059
TESTS_NAMES = [t.base for t in TESTS]
6160

6261

0 commit comments

Comments
 (0)