Open ryanmrichard opened 2 years ago
This is a standard Python feature. The solution that we need to use is "from x import y". Hence:
from simde import chemist
mol = chemist.Molecule()
Others that work:
from chemist import chemist
from nwchemex import chemist
I don't think this is the same as #31. I think this is a problem with us actually copying the subpackages instead of importing them.
Admittedly I'm pretty weak when it comes to the mechanics of Python's import mechanism, so this might be a Python error on my side.
Anyways, since this works:
I would have expected:
to work. Instead I get
ModuleNotFoundError: No module named 'simde.chemist'
. Assuming this isn't a problem with my Python, I think what's happening is that the Chemist found by SimDE isn't actually a Python module (i.e., it doesn't have an__init__.py
file). Interestingly:works which suggests to me that we might have a Python stack where each module x includes copies of the repos below it, instead of simply than importing them as submodules.
I'm going to throw this issue in the .github repo, but it should be moved to the appropriate repo if .github isn't it.