Unresolved import problem for files in sub-directories in a workspace #1099
Description
Its hard for me to explain my exact issue because I don't know all the correct terminology.
Basically if I try to import one of my own python files into another of my own python files whilst both are in the same "sub-directory" of my "main" workspace directory then I get an unresolved import problem unless I put the full file path from the "main" directory into the import in which case the python files no longer run.
Please see my example below.
Say I have files setup like this: (I've obviously omitted folders and files you don't need to see)
C:.
│ Potassco.code-workspace
│
├───.vscode
│ settings.json
│
└───Work
└───Hospitality_Domain
└───Version_7
│ Architecture.lp
│ domain_setup.lp
│ Parser.py
│ Robot_Hotel.sp
│ Simulate.py
│ SPARC.jar
│
└───__pycache__
Parser.cpython-36.pyc
If I try to import Parser.py into Simulate.py as such:
import Parser
I get the unresolved import problem but the code runs just fine (as we would expect).
However if I instead put this:
import Work.Hospitality_Domain.Version_7.Parser
I do not get the unresolved import but the code does not run, (which is also what I would expect).
I'm guessing my problem is probably something simple, can anyone help?