Using PythonPath under Windows Vista.
bockman at virgilio.it
Sun Jan 4 14:34:38 CET 2009
On Sun, 04 Jan 2009 04:56:51 -0800, Morgul Banner Bearer wrote:
> Hi Everybody,
> The behaviour of the program is as follows :
> In a Dos Box, the program executes nicely when i type :
> "c\python26>python c:\python26\work\brian.py".
> Now i understand that- because I set the Pythonpath- the program
> should also run if i type:
> "c\python26>python brian.py"
> (under these conditions Python should look for the file brian.py in
> the folders specified in the
> Pythonpath). However, this does not work, but gives : "Can't open
> file... No such file or directory".
> I have not found further info availlable on bulletin boards on the
> internet, so if anybody can post
> the solution here, that would help me out.
AFAIK, PYTHONPATH only works for the imported modules. For the main
module, you have to do give the full path.
OR you could try out the new flag -m, which allows to run directly a
module from the standard library and - I guess - also user modules if
PYTHONPATH is set correcltly. So try from a "DOS Box" the command:
"c\python26>python -m brian.py"
More information about the Python-list