when i initially ran
$ pip install pandas
it gave me an error that i don't have permissions. then when i tried
$ sudo pip install pandas
it gave me this -
fatal error: Python.h: No such file or directory
After some search, i came across this command
$ sudo pip install -U pandas
after a very, very verbose output, it gave the same error but this time it prompted me that i might need/want to install python-dev & python-setuptools after installing python-dev, pip install pandas worked fine and without a hitch!
So, my question is, does anyone know why this problem occurred?! Has this occurred before?! and what does the -U in $ pip install -U ... stand for?! it isn't mentioned in the help page for pip, i checked!
Also, i know that there's a log file for at /home/user/.pip/pip.log but instead of appending error messages to the log file, it gets rewritten each time there's pip runs into a problem.
Is there anyway to fix this?! Also, can i make pip log every install as well and not just the ones that went wrong! instead of having to do
$ pip install ... >> LOG_FILE
everytime!
EDIT 1 : turns out i didn't do enough research, i found that Python.h isn't necessarily installed by default though i have them installed.
But i'd still like to know what the -U stands for and how to keep a log file in pip.