You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
could you please upgrade setuptools version to latest #1012
I am using python:3.11-alpine3.21 docker image from docker hub however this docker image is having one high level of vulnerability which is related to setuptools library. I would recommend you to upgrade the setuptools version from 65.5.1 to 76.1.0, which can help us to resolve the currently present vulnerability and republish the docker image to dockerhub
So this is expected, and not something that will be changed in these images. (Updating to setuptools 70+ would be a breaking change for a start.)
You will either need to either:
Update to Python 3.12 or newer (which no longer bundles setuptools)
Update setuptools in your own Dockerfile
Ask upstream CPython to update to newer setuptools in Python 3.11
Suppress the vulnerability alert if appropriate (you didn't say what vulnerability you were referring to, but it's quite possible it's a non-issue in practice - many setuptools codepaths are not used when it's used as a pip build backend, or need several other criteria to be a problem etc)
This change hasn't yet been released upstream, but will be made available during the next patch release for those older versions (which happens sporadically; typically when there are a collection of security fixes that need to be released).
I believe the image building scripts in this repo will automatically pick up the change, since they use the setuptools version from upstream (with the exception of a 65.5.0 -> 65.5.1 mapping, which will now be redundant and a no-op):
Once the upstream changes are released, we could probably simplify/clean-up the versioning script further (like we did for the pip/wheel versions), since we'd never be customising the version in practice any more.
Reacted by yosifkit, Tianon Gravi, Georgios Adzhygai and Gabi Cavalcante
Activity
edmorley commentedon Mar 19, 2025
These images by design use the pip/setuptools versions that are bundled with the version of Python being installed.
Python 3.11 comes with setuptools v65.5.0:
https://github.com/python/cpython/tree/3.11/Lib/ensurepip/_bundled
So this is expected, and not something that will be changed in these images. (Updating to setuptools 70+ would be a breaking change for a start.)
You will either need to either:
DockerfileSee also:
yosifkit commentedon Mar 20, 2025
@edmorley is correct. We do not update
setuptoolsin the image; we just include the bundled version. See also #781 (comment)edmorley commentedon Jun 16, 2025
It looks like upstream CPython has now updated setuptools in all non-EOL Python versions that still ship it (so 3.9, 3.10, 3.11):
This change hasn't yet been released upstream, but will be made available during the next patch release for those older versions (which happens sporadically; typically when there are a collection of security fixes that need to be released).
I believe the image building scripts in this repo will automatically pick up the change, since they use the setuptools version from upstream (with the exception of a
65.5.0->65.5.1mapping, which will now be redundant and a no-op):python/versions.sh
Lines 162 to 188 in 3fae0a1
Once the upstream changes are released, we could probably simplify/clean-up the versioning script further (like we did for the pip/wheel versions), since we'd never be customising the version in practice any more.