I am developing my code in the path: /py/myscripts /py/mylib In order to "import mylib", I need to add /py/mylib to PYTHONPATH.
Now I want to save a snapshot of the current code in the production directory, I will copy all in: /prod/myscripts /prod/mylib The problem now is that when I execute /prod/myscripts/any_script.py, every "import" will look at PYTHONPATH and therefore it will load the modules from /py/mylib. On the contrary I want to load it from /prod/mylib. Is there an elegant way to cope with this? thanks, Jacopo -- http://mail.python.org/mailman/listinfo/python-list