On 05/30/2017 09:27 PM, Mahmood Naderan via Python-list wrote:
Well yes. It looks in other folders
But
$ find /opt -name openpyxl
/opt/rocks/lib/python2.6/site-packages/openpyxl
So, your pip knows about a search path that python doesn't know.
That can have a number of reasons still and one would be Pavol's
suggestion that your pip command may run on a different python than the
python you invoke with the commmand 'python'. However, this would
require that you have two separate installs of python2.6 on your system,
which sounds rather unlikely.
Another possibility is that pip picks up additional directories from a
pip config file somewhere. To check this you could compare
pip show openpyxl
to
pip show --isolated openpyxl
(which would ignore any pip config file or environment variable)
or (since I don't remember what commands your rather old version of pip
will support):
pip list vs pip list --isolated
(which should give all installed packages pip knows about with and
without additional config settings.
Wolfgang
--
https://mail.python.org/mailman/listinfo/python-list