Skip to content Skip to sidebar Skip to footer

Python Module Not Found Issues After Moving Directory

I am working on some repacking of a project that has a variety of different technologies involved. I am trying to move a python module into the project structure for storage in git

Solution 1:

When importing python looks from the root of the structure. In the first example the root is "nbcu_nes_ingest", so when it looks for "Documents" it is directly under the root directory. However, in the second example the root is now "slicer" and there is no "Documents" sub dir directly beneath that. So your import would have to now be "from nbcu_nes_ingest.Documents import NCStoryDocument"


Post a Comment for "Python Module Not Found Issues After Moving Directory"