Direct import fails but “from … import …” succeeds
I have a Python module called my_module.py
in a folder ~/my_module
. I want to call this module from a Python interpreter and I don’t know its directory. I run:
I have a Python module called my_module.py
in a folder ~/my_module
. I want to call this module from a Python interpreter and I don’t know its directory. I run: