While testing a patch for bug 361867, I noticed that /usr/bin/pydoc2.4 and /usr/bin/pydoc2.5 have #!/usr/bin/python on the first line. This causes them to display documentation for the currently active version of python rather than the expected version.
I noticed that this has been fixed at least in 2.6.6-r2 on my system. However, it now uses /usr/bin/python2.6 while using /usr/bin/env python2.6 would be more compatible with virtualenv.
+*python-2.6.8-r2 (30 Jun 2013) +*python-2.5.4-r6 (30 Jun 2013) + + 30 Jun 2013; Mike Gilbert <floppym@gentoo.org> +files/python-2.5-tcl86.patch, + +python-2.5.4-r6.ebuild, +python-2.6.8-r2.ebuild: + Apply patch to allow old python versions to use tk-8.6, bug 454342. Also fix + the python shebang in idle2.5 and pydoc2.5, bugs 275241 and 383009.