Drop support for Python 2.7, 3.4, 3.5 and PyPy#1364
Merged
Conversation
Python 2.7, 3.4 and 3.5: - are end-of-life upstream, so no longer receiving security updates making them insecure to use - have previously been deprecated on the platform, with deprecation warnings - have extremely low usage (Python 3.4 and 3.5 combined account for < 0.01%, and Python 2.7 is < 0.3%) - are only available on Heroku-18, which itself is deprecated For PyPy: - it was only ever a beta feature, and has been undocumented for some time - the versions available on Heroku are outdated and insecure - it has extremely low usage (<0.01%) - it's already only available on older stacks (Heroku-18 and Heroku-20) - in general, only advanced users should be using PyPy as it comes with a number of caveats, and depending on the use-case may not offer enough of a performance improvement (over newer CPython, which has been getting faster) to be worth the trade-offs. Users wanting to continue using the above versions can: - Pin to an older buildpack release, using the buildpack URL of `https://github.com/heroku/heroku-buildpack-python#v218` - (For older CPython) Upgrade to a newer Python version by updating their `runtime.txt` or `Pipfile` + `Pipfile.lock`. - (For PyPy) Switch to CPython by updating their `runtime.txt` to use `python-X.Y.Z` instead of `pypy*`. - (For PyPy) Switch to the container stack and use an official upstream PyPy Docker image instead. GUS-W-11796962. GUS-W-11796984. GUS-W-11796975.
fc7fc0b to
6e1c077
Compare
colincasey
approved these changes
Sep 22, 2022
Member
Author
|
Added docs to the Python 2.7 EOL FAQ about how to pin to the previous buildpack release, to continue building with Python 2: |
edmorley
added a commit
that referenced
this pull request
Apr 18, 2024
For cases where a requested Python version is both (a) EOL, and (b) was never built for that stack (such as is the case when we add new stacks), previously the generic "version isn't available for this stack" error message was shown instead of the more specific EOL Python version error message. Now, the EOL version check is performed first before the S3 presence check, so the more specific EOL message is shown for this case. In addition to improving the UX, making this change now reduces the test fixture churn both when we add a new stack and for #1567. I've also dropped the "PyPy is no longer supported" error message and associated test, since very few apps ever used it and it's now been 19 months since support was removed in #1364, so it's fine to show the generic "Python version isn't available" error message for it instead. GUS-W-15541279.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Python 2.7, 3.4 and 3.5:
For PyPy:
The suggested migration paths are:
runtime.txtorPipfile+Pipfile.lock.runtime.txtto specifypython-X.Y.Zinstead ofpypy*.Otherwise, users wanting to continue using the above versions can:
https://github.com/heroku/heroku-buildpack-python#v218GUS-W-11796962.
GUS-W-11796984.
GUS-W-11796975.