I am faced with a unique situation, slightly trivial but painful.
I need to use Python 2.6.6 because NLTK is not ported to Python 3 (that\'s what I could gather).
You can specify the version you want in the shebang line. I just ran into this when a VM my Ops guy set up had Python 2.6 in /usr/bin/python2.6, and I needed 2.7 for a few features. He installed it for me at /usr/bin/python2.7.
My old shebang:
#!/usr/bin/env python
stopped working, because /usr/bin/python was a link to /usr/bin/python2.6. What wound up fixing the problem, and working across Windows, Linux, and OSX, was changing the shebang to:
#!/usr/bin/env python2.7
It should work for any version, I believe.