I often had the problem that the Interactive Console from Pydev does not start in the project source folder. On Windows, the working directory is per default:
So I wrote a short script the set a working directory automatically which can be added to “Initial interpreter commands” under Preferences > Pydev > Interactive Console. Here it is:
1 2 3 4 5 6 7 8 9 10
Please note, that there has to be two newlines at the end of the script. Otherwise the
else-block wouldn’t be left correctly.
This works fine if you doesn’t have any custom paths in your PYTHONPATH environment variable.