Importing A Module From An Upper Directory Within A Package When The Package Is Imported From Another Place
I have a project that I am having problems with. kreveik. |-- classes | |-- baseclasses.py | |-- family.py | |-- __init__.py | `-- network.py |-- family | |-- __init__.py
Solution 1:
You must also reference the enclosing package when importing from a sub-package.
In this example, in network.py, use
from kreivik.classesimport *
Post a Comment for "Importing A Module From An Upper Directory Within A Package When The Package Is Imported From Another Place"