Python: Add missing type-tracking step for django.views

Easy to overlook, and will onyl be caught by tests if they use `import
parent.thing` and not `from parent import thing`
This commit is contained in:
Rasmus Wriedt Larsen
2021-01-28 12:08:55 +01:00
parent 54725ccbb9
commit 173012578e
2 changed files with 2 additions and 2 deletions

View File

@@ -35,7 +35,7 @@ private module Django {
* WARNING: Only holds for a few predefined attributes.
*/
private DataFlow::Node django_attr(DataFlow::TypeTracker t, string attr_name) {
attr_name in ["db", "urls", "http", "conf"] and
attr_name in ["db", "urls", "http", "conf", "views"] and
(
t.start() and
result = DataFlow::importNode("django" + "." + attr_name)

View File

@@ -39,7 +39,7 @@ class ClassView(View, Foo):
# direct import with full path to `View` class (previously not supported)
class ClassView2(django.views.generic.base.View):
def get(self, request): # $ MISSING: requestHandler
def get(self, request): # $ requestHandler
pass