CodeQL library for Python
Search

Predicate import_from_dot_in_init

Holds if f is an import of the form from .[...] import ... and the enclosing scope is an init module

Import path

import python
predicate import_from_dot_in_init(ImportExprNode f)