I have the following directory /home/me/projects/modulename.

I update PYTHONPATH using the following command:
export PYTHONPATH=$PYTHONPATH:/home/me/projects/modulename

It seems to have been added:
[me@machine ~]$ python -c "import sys; print(sys.path)"
['',... '/home/me', '/home/me/projects/modulename', ...]

But import modulename does not work:
[me@machine ~]$ python -c "import modulename"
Traceback (most recent call last):
  File "<string>", line 1, in <module>
ImportError: No module named modulename

Does anyone know what's wrong?
-- 
https://mail.python.org/mailman/listinfo/python-list

Reply via email to