MCPcopy Index your code
hub / github.com/python/mypy / is_package_module

Method is_package_module

mypyc/irbuild/builder.py:1170–1173  ·  view source on GitHub ↗

Is the given module a package (i.e., an __init__.py file)?

(self, module: str)

Source from the content-addressed store, hash-verified

1168 return self.mapper.group_map.get(module) == self.mapper.group_map.get(self.module_name)
1169
1170 def is_package_module(self, module: str) -> bool:
1171 """Is the given module a package (i.e., an __init__.py file)?"""
1172 st = self.graph.get(module)
1173 return st is not None and st.tree is not None and st.tree.is_package_init_file()
1174
1175 def is_native_ref_expr(self, expr: RefExpr) -> bool:
1176 return self.mapper.is_native_ref_expr(expr)

Callers 1

gen_importMethod · 0.95

Calls 2

is_package_init_fileMethod · 0.80
getMethod · 0.45

Tested by

no test coverage detected