tidy: Update Python version requirements to 3.11 - #160896
Conversation
| @@ -1,5 +1,5 @@ | |||
| # | |||
| # This file is autogenerated by pip-compile with Python 3.10 | |||
| # This file is autogenerated by pip-compile with Python 3.11 | |||
There was a problem hiding this comment.
To update this file I ran:
docker run --rm \
-v "$PWD":/workspace \
-w /workspace \
python:3.11-slim \
bash -c '
python -m pip install --no-cache-dir \
pip-tools==7.5.3 \
&&
pip-compile --generate-hashes --strip-extras \
src/tools/tidy/config/requirements.in
'
This comment has been minimized.
This comment has been minimized.
3194a6b to
dfe7f30
Compare
This comment has been minimized.
This comment has been minimized.
dfe7f30 to
dee0f81
Compare
| FROM ghcr.io/rust-lang/ubuntu:22.04 | ||
|
|
||
| ARG DEBIAN_FRONTEND=noninteractive | ||
| # Install python3.11 because python3 in ubuntu22 resolves to python3.10, which is EOL in October 2026. |
There was a problem hiding this comment.
I couldn't update to ubuntu 24 because python2.7 is not available there from apt.
There was a problem hiding this comment.
As discussed in #t-infra/bootstrap > Do we need to support Python 2?, we should just kick out the Python 2.7 package.
|
|
|
r? @jieyouxu rustbot has assigned @jieyouxu. Use Why was this reviewer chosen?The reviewer was selected based on:
|
| @@ -12,6 +13,8 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ | |||
| ca-certificates \ | |||
| python2.7 \ | |||
There was a problem hiding this comment.
Remark: hm, do we actually need python2.7? I guess we have something exercising bootstrap entry script still works with python 2.7? If we drop 2.7 support then we can bump to ubuntu 24?
There was a problem hiding this comment.
If we drop 2.7 support then we can bump to ubuntu 24?
yes.
do we actually need
python2.7? I guess we have something exercising bootstrap entry script still works with python 2.7?
The comment in the dockerfile says "intentionally uses python2 for x.py so we can test it still works."
I have no context if this comment is still valid or not :/
I would approve this PR like this and we can remove python2.7 support in another PR if we want 👍
EDIT: I saw the linked zulip topic now. I'll remove python2 support 👍
Similar to #160429
I'm updating to 3.11 as requested in #160429 (comment) because 3.10 is EOL in 2 months.