If I find the vim command line
:python import os;print os.getenv('PYTHONPATH')
I get the path if I close vim and on the same terminal do
echo $PYTHONPATH
I get another completely different path. Why is this where vim gets this path? This is relevant because autocomplete cannot find modules, so it does not work. I know this because if I try again from vim cli
:python import django
It fails, but if I exit vim and print
python >>> import django
There are no errors! What's going on here? I am using virtualenv and I checked the activation source and did not change PYTHONPATH. I tried this without virtualenv, the same problem.
Update: The line I used to configure the Vim source before compiling it.
./configure --prefix = $ {HOME} / apps / vim73 --with-features = huge --enable-gui = gnome2 --enable-pythoninterp --enable-rubyinterp --enable-multibyte --with-python- config-dir = / usr / lib / python2.6 / config
source share