I don't quite understand the apparent disagreement in versions between the various Python 2 packages and the Python 2 interpreter on my Ubuntu 16.04 system.
Running
$ readlink -e $(which python python2)
/usr/bin/python2.7
/usr/bin/python2.7
$ python --version && python2 --version
Python 2.7.12
Python 2.7.12
tells me that python
and python2
are symlinked to python2.7
and the version of the Python 2 interpreter on my system is Python 2.7.12
. So far so good, nothing surprising.
Running
$ dpkg -s python | grep Version
Version: 2.7.11-1
tells me that the version of the python
package is 2.7.11-1
, which disagrees with the version of the Python 2 interpreter.
On the other hand, running
$ dpkg -s python2.7 | grep Version
Version: 2.7.12-1~16.04
tells me that the version of the python2.7
package is 2.7.12
, which agrees with the version of the Python 2 interpreter.
Given that the version of the Python 2 interpreter is 2.7.12
, is the interpreter then provided by only the python2.7
package? If so, what does the python
package do if it doesn't provide the interpreter that the system currently uses?
python
andpython2.7
packages in the official 16.04 repositories are at version2.7.11-1
. Do you have third-party repositories enabled? – fkraiem Sep 17 '16 at 12:49