-
-
Notifications
You must be signed in to change notification settings - Fork 646
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pin test_package_pex_environment
's image to a particular sha
#19324
Pin test_package_pex_environment
's image to a particular sha
#19324
Conversation
@@ -428,8 +429,8 @@ def test_packaged_pex_environment(rule_runner: RuleRunner) -> None: | |||
rule_runner.write_digest(context.digest, path_prefix="contents") | |||
with zipfile.ZipFile(os.path.join(rule_runner.build_root, "contents", pex_file), "r") as zf: | |||
assert json.loads(zf.read("PEX-INFO"))["distributions"].keys() == { | |||
"psutil-5.9.2-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't know why the distributions changed from 3.9 to 3.7 (both locally and in CI)?
@@ -393,7 +393,8 @@ def test_packaged_pex_environment(rule_runner: RuleRunner) -> None: | |||
""" | |||
docker_environment( | |||
name="python_38", | |||
image="python:3.8", | |||
image="python:3.8-buster@sha256:bc4b9fb034a871b285bea5418cedfcaa9d2ab5590fb5fb6f0c42aaebb2e2c911", | |||
platform="linux_x86_64", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The sha256 digest is specific to a particular platform, so we need to be specific here, or else running on arm64 (e.g. M1 Mac) fails because the x86-64 image doesn't match the default (linux_arm64
).
test_package_pex_environment
's image to a particular sha
Hey y'all. I'm going to merge this PR since it unblocks CI for other PRs. We can address concerns in follow-up PRs |
This pins the docker image used in `src/python/pants/backend/docker/util_rules/docker_build_context_test.py:test_packaged_pex_environment` to https://hub.docker.com/layers/library/python/3.8-buster/images/sha256-bc4b9fb034a871b285bea5418cedfcaa9d2ab5590fb5fb6f0c42aaebb2e2c911?context=explore, which is (at the time of writing) the most recent `3.8-buster` image. This test has recently started failing with an error when building `psutil`: ``` E psutil/_psutil_common.c:9:10: fatal error: Python.h: No such file or directory E 9 | #include <Python.h> E | ^~~~~~~~~~ E compilation terminated. E error: command '/usr/bin/x86_64-linux-gnu-gcc' failed with exit code 1 E ---------------------------------------- E ERROR: Failed building wheel for psutil ``` The failure correlates with the change in base image (from buster to bookworm) docker-library/python#822, which seems to have been published at 2023-06-14T23:05Z (https://hub.docker.com/layers/library/python/3.8/images/sha256-b904ee5365f53d19de5ff11c1ce96a616224a55306d55e3cf29a11e969a3a7e0?context=explore). This change, that pins to the older image, seems to fix the problem. This fixes https://pantsbuild.slack.com/archives/C0D7TNJHL/p1686790197387729
This pins the docker image used in `src/python/pants/backend/docker/util_rules/docker_build_context_test.py:test_packaged_pex_environment` to https://hub.docker.com/layers/library/python/3.8-buster/images/sha256-bc4b9fb034a871b285bea5418cedfcaa9d2ab5590fb5fb6f0c42aaebb2e2c911?context=explore, which is (at the time of writing) the most recent `3.8-buster` image. This test has recently started failing with an error when building `psutil`: ``` E psutil/_psutil_common.c:9:10: fatal error: Python.h: No such file or directory E 9 | #include <Python.h> E | ^~~~~~~~~~ E compilation terminated. E error: command '/usr/bin/x86_64-linux-gnu-gcc' failed with exit code 1 E ---------------------------------------- E ERROR: Failed building wheel for psutil ``` The failure correlates with the change in base image (from buster to bookworm) docker-library/python#822, which seems to have been published at 2023-06-14T23:05Z (https://hub.docker.com/layers/library/python/3.8/images/sha256-b904ee5365f53d19de5ff11c1ce96a616224a55306d55e3cf29a11e969a3a7e0?context=explore). This change, that pins to the older image, seems to fix the problem. This fixes https://pantsbuild.slack.com/archives/C0D7TNJHL/p1686790197387729
This pins the docker image used in `src/python/pants/backend/docker/util_rules/docker_build_context_test.py:test_packaged_pex_environment` to https://hub.docker.com/layers/library/python/3.8-buster/images/sha256-bc4b9fb034a871b285bea5418cedfcaa9d2ab5590fb5fb6f0c42aaebb2e2c911?context=explore, which is (at the time of writing) the most recent `3.8-buster` image. This test has recently started failing with an error when building `psutil`: ``` E psutil/_psutil_common.c:9:10: fatal error: Python.h: No such file or directory E 9 | #include <Python.h> E | ^~~~~~~~~~ E compilation terminated. E error: command '/usr/bin/x86_64-linux-gnu-gcc' failed with exit code 1 E ---------------------------------------- E ERROR: Failed building wheel for psutil ``` The failure correlates with the change in base image (from buster to bookworm) docker-library/python#822, which seems to have been published at 2023-06-14T23:05Z (https://hub.docker.com/layers/library/python/3.8/images/sha256-b904ee5365f53d19de5ff11c1ce96a616224a55306d55e3cf29a11e969a3a7e0?context=explore). This change, that pins to the older image, seems to fix the problem. This fixes https://pantsbuild.slack.com/archives/C0D7TNJHL/p1686790197387729
…y-pick of #19324) (#19337) This pins the docker image used in `src/python/pants/backend/docker/util_rules/docker_build_context_test.py:test_packaged_pex_environment` to https://hub.docker.com/layers/library/python/3.8-buster/images/sha256-bc4b9fb034a871b285bea5418cedfcaa9d2ab5590fb5fb6f0c42aaebb2e2c911?context=explore, which is (at the time of writing) the most recent `3.8-buster` image. This test has recently started failing with an error when building `psutil`: ``` E psutil/_psutil_common.c:9:10: fatal error: Python.h: No such file or directory E 9 | #include <Python.h> E | ^~~~~~~~~~ E compilation terminated. E error: command '/usr/bin/x86_64-linux-gnu-gcc' failed with exit code 1 E ---------------------------------------- E ERROR: Failed building wheel for psutil ``` The failure correlates with the change in base image (from buster to bookworm) docker-library/python#822, which seems to have been published at 2023-06-14T23:05Z (https://hub.docker.com/layers/library/python/3.8/images/sha256-b904ee5365f53d19de5ff11c1ce96a616224a55306d55e3cf29a11e969a3a7e0?context=explore). This change, that pins to the older image, seems to fix the problem. This fixes https://pantsbuild.slack.com/archives/C0D7TNJHL/p1686790197387729 Co-authored-by: Huon Wilson <huon@exoflare.io>
…y-pick of #19324) (#19335) This pins the docker image used in `src/python/pants/backend/docker/util_rules/docker_build_context_test.py:test_packaged_pex_environment` to https://hub.docker.com/layers/library/python/3.8-buster/images/sha256-bc4b9fb034a871b285bea5418cedfcaa9d2ab5590fb5fb6f0c42aaebb2e2c911?context=explore, which is (at the time of writing) the most recent `3.8-buster` image. This test has recently started failing with an error when building `psutil`: ``` E psutil/_psutil_common.c:9:10: fatal error: Python.h: No such file or directory E 9 | #include <Python.h> E | ^~~~~~~~~~ E compilation terminated. E error: command '/usr/bin/x86_64-linux-gnu-gcc' failed with exit code 1 E ---------------------------------------- E ERROR: Failed building wheel for psutil ``` The failure correlates with the change in base image (from buster to bookworm) docker-library/python#822, which seems to have been published at 2023-06-14T23:05Z (https://hub.docker.com/layers/library/python/3.8/images/sha256-b904ee5365f53d19de5ff11c1ce96a616224a55306d55e3cf29a11e969a3a7e0?context=explore). This change, that pins to the older image, seems to fix the problem. This fixes https://pantsbuild.slack.com/archives/C0D7TNJHL/p1686790197387729 Co-authored-by: Huon Wilson <huon@exoflare.io>
…y-pick of #19324) (#19336) This pins the docker image used in `src/python/pants/backend/docker/util_rules/docker_build_context_test.py:test_packaged_pex_environment` to https://hub.docker.com/layers/library/python/3.8-buster/images/sha256-bc4b9fb034a871b285bea5418cedfcaa9d2ab5590fb5fb6f0c42aaebb2e2c911?context=explore, which is (at the time of writing) the most recent `3.8-buster` image. This test has recently started failing with an error when building `psutil`: ``` E psutil/_psutil_common.c:9:10: fatal error: Python.h: No such file or directory E 9 | #include <Python.h> E | ^~~~~~~~~~ E compilation terminated. E error: command '/usr/bin/x86_64-linux-gnu-gcc' failed with exit code 1 E ---------------------------------------- E ERROR: Failed building wheel for psutil ``` The failure correlates with the change in base image (from buster to bookworm) docker-library/python#822, which seems to have been published at 2023-06-14T23:05Z (https://hub.docker.com/layers/library/python/3.8/images/sha256-b904ee5365f53d19de5ff11c1ce96a616224a55306d55e3cf29a11e969a3a7e0?context=explore). This change, that pins to the older image, seems to fix the problem. This fixes https://pantsbuild.slack.com/archives/C0D7TNJHL/p1686790197387729 Co-authored-by: Huon Wilson <huon@exoflare.io>
This pins the docker image used in
src/python/pants/backend/docker/util_rules/docker_build_context_test.py:test_packaged_pex_environment
to https://hub.docker.com/layers/library/python/3.8-buster/images/sha256-bc4b9fb034a871b285bea5418cedfcaa9d2ab5590fb5fb6f0c42aaebb2e2c911?context=explore, which is (at the time of writing) the most recent3.8-buster
image.This test has recently started failing with an error when building
psutil
:The failure correlates with the change in base image (from buster to bookworm) docker-library/python#822, which seems to have been published at 2023-06-14T23:05Z (https://hub.docker.com/layers/library/python/3.8/images/sha256-b904ee5365f53d19de5ff11c1ce96a616224a55306d55e3cf29a11e969a3a7e0?context=explore).
This change, that pins to the older image, seems to fix the problem.
This fixes https://pantsbuild.slack.com/archives/C0D7TNJHL/p1686790197387729