types.ModuleType.__package__

__package__

Which package a module belongs to. If the module is top-level (i.e. not a part of any specific package) then the attribute should be set to '', else it should be set to the name of the package (which can be __name__ if the module is a package itself). Defaults to None.

Changed in version 3.4: Defaults to None. Previously the attribute was optional.

doc_python
2016-10-07 17:45:53
Comments
Leave a Comment

Please login to continue.