We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 2129949 commit 39705cfCopy full SHA for 39705cf
python/ql/src/semmle/python/dataflow/SsaDefinitions.qll
@@ -404,11 +404,11 @@ cached module SsaSource {
404
* to the __init__ module of that package.
405
*/
406
cached predicate init_module_submodule_defn(PythonSsaSourceVariable var, ControlFlowNode f) {
407
+ var instanceof GlobalVariable and
408
exists(Module init |
409
init.isPackageInit() and exists(init.getPackage().getSubModule(var.getName())) and
410
init.getEntryNode() = f and
- var.getScope() = init and
411
- var instanceof GlobalVariable
+ var.getScope() = init
412
)
413
}
414
0 commit comments