distroless icon indicating copy to clipboard operation
distroless copied to clipboard

support python 3.10

Open mrchypark opened this issue 3 years ago • 15 comments

now distroless python3 is 3.9 version.

any plan to python 3.10 support?

or, How can I build python 3.10 image for personal use?

mrchypark avatar Sep 19 '22 15:09 mrchypark

is 3.10 is on debian11, we can swap about 3.9 for 3.10

loosebazooka avatar Sep 19 '22 15:09 loosebazooka

@loosebazooka good news :)

mrchypark avatar Sep 19 '22 15:09 mrchypark

Sorry that was a question... is it?

loosebazooka avatar Sep 19 '22 15:09 loosebazooka

Oh, you question to me about python 3.10 is on debian11?

I don't know. let's find out.

mrchypark avatar Sep 19 '22 15:09 mrchypark

maybe not yet. just unstable and test suite support.

https://packages.debian.org/search?suite=default&section=all&arch=any&searchon=names&keywords=python3.10

mrchypark avatar Sep 19 '22 15:09 mrchypark

Debian is always behind with python in stable. It would be great if distroless ships python independently without relying on Debian releases (Similar to what's done with Node), so we could have the latest patches and multiple releases (3.9, 3.10).

The limitation is that python doesn't provide any binaries, need to compile.

@loosebazooka I wonder if it would be doable to build python from source in the CI environment and maintain something with bazel. I'm happy to give it a try if possible.

It needs gcc and some source packages to build few common dependencies.

ericofusco avatar Oct 22 '22 12:10 ericofusco

Sounds to me like it should be the responsibility of the Python project to add distroless variants of all of their supported Python versions given that they already support a wide matrix of Python versions on most common distribution images. Otherwise all you're doing is pushing a lot of maintenance and testing onto the Distroless developers when the Python project already has significant CI and tooling setup around supporting their existing images.

ReillyBrogan avatar Oct 27 '22 21:10 ReillyBrogan

That would be nice. Python support is still in experimental because we have to do a few weird things to get it to work. Thats not to say it's not up to date.. it is. The build is just a bit strange. If we could get someone from the python project to help out, it would be very nice.

loosebazooka avatar Oct 27 '22 22:10 loosebazooka

Shameless plug, but the Python wolfi image is built with python 3.10: https://github.com/wolfi-dev/os/blob/main/python3.yaml

You can try it at cgr.dev/chainguard-images/python

dlorenc avatar Oct 27 '22 22:10 dlorenc

Any update regarding this? We'd also like to migrate to 3.10 but not having to do a custom implementation moving away from the "official" distroless images.

goncafab avatar Dec 19 '22 16:12 goncafab

It would be amazing to have support for 3.10 and 3.11

Corfucinas avatar Jan 05 '23 18:01 Corfucinas

The architecture of this repo/project means that they can't really ship versions that aren't already in debian. Bookworm is shipping 3.10, but this repo is still on bullseye.

The alternative here: https://github.com/chainguard-images/images/tree/main/images/python/configs based on Wolfi instead of debian is currently shipping 3.11 but we're working on support for multiple versions at once. Please let me know if you want to try that or run into any issues. The image is at cgr.dev/chainguard/python

dlorenc avatar Jan 05 '23 19:01 dlorenc

https://github.com/GoogleContainerTools/distroless/issues/1337

Debian 12 (Bookworm) has been released, and it looks like it ships with Python 3.11.

https://packages.debian.org/bookworm/python3

snorfalorpagus avatar Jun 12 '23 11:06 snorfalorpagus

I have been building python 3.9 to 3.11 containers with deadsnake python releases. They are meant for ubuntu but they are perfectly compatible with debian

ding-ma avatar Jul 13 '23 22:07 ding-ma