I’ve been using python 2.7 and after installation of python 2.7. All of the scripts have run successfully, but suddenly today, when I run python, it is recognized with python 2.6, so for one of the python packages I get the following error:
/Library/Frameworks/Python.framework/Versions/2.6/Resources/Python.app/Contents/MacOS/Python:
No module named htseq-count
i am not sure why it happens. The path environment variable for python is set to:
PATH="/Library/Frameworks/Python.framework/Versions/2.7/Resources/bin:${PATH}" export PATH
How do I fix this error?
If your code relies on a particular version of Python, you should specify
python2.7orpython2.6instead of justpython.If this “suddenly” happened it’s possible that installing some other software modified your
$PATHso that the old version of Python now has priority (it’s possible for multiple versions to be on your$PATH; it uses the first one it finds).If you move these two lines to the bottom of the file they’re in (maybe
~/.profile) it may correct this.You can type
which pythonin Terminal you can see what binary it finds when looking forpythonon your$PATH.If you don’t mind using Python 2.6, you can probably install the missing package by typing this in your terminal: