Will PIP work for python 2.7 after its End of Life on 1st Jan 2020
Yes. Python 2 support will live in a "community maintained" state though. Folks who care about it, will have to step up and fix issues -- pip maintainers will likely not work on resolving Python 2 issues. We've documented the exact expectations at:
https://pip.pypa.io/en/stable/development/release-process/#python-2-support
Note that pip maintainers are volunteers and I, personally, am not interested in doing free work for corporations / organizations which are stuck on an EOL'ed Python even after having a decade to switch.
Yes, Pip for python2.7 is part of Ubuntu 18, which EOLs in April 2028. Ubuntu is really good about maintaining their distros.
Then, by April 2028, it is likely that a new Python2.7-compatible language will be developed and maintained, which will support pip
or something similar. Some kind of compiler hook will be added to Python3 to change the str
back to byte strings and make the parenthesis on print
optional. Or maybe we'll switch to Cython
or some other implementation of Python2.7. But don't worry about that for a few years (unless you have a lot of free time).
You need to make sure you have the right version of pip
for Python 2.7:
pip install --upgrade "pip < 21.0"
That versions will be working for some time. Sooner or later they fail because PyPI host changes SSL configuration to one that Python 2.7 doesn't handle. But I'm sure we have a few years before that.
A few additional version limits for important tools to retain compatibility with Python 2.7:
pip install --upgrade "setuptools < 45" "Sphinx < 2.0" "pytest < 5.0"
If you use other tools follow their announcements thoroughly to catch them stopping supporting 2.7.