Skip to content

Conversation

vbvictor
Copy link
Contributor

@vbvictor vbvictor commented Sep 27, 2025

I'm trying to make pr-code-format.yml job run natively on ci-ubuntu-24.04 container.
As it appears, ci-ubuntu-24.04 already has latest clang-format, python3.12 installed, but python3.12 needs venv to work properly, and Ubuntu asks for python3-venv package to be installed to create a venv.

FYI I hacked it with --break-system-packages to test and clang-format job runs a lot faster https://github.com/llvm/llvm-project/actions/runs/18064896361/job/51406365488#logs (skipping 1min long clang-format installation). Just don't look at "Initialize containers" taking 6min, it usually takes 15-20sec

@llvmbot
Copy link
Member

llvmbot commented Sep 27, 2025

@llvm/pr-subscribers-github-workflow

Author: Baranov Victor (vbvictor)

Changes

I'm trying to make pr-clang-format.yml job run natively on ci-ubuntu-24.04 container.
As it appears, It already has clang-format-21.1.0, python3.12 installed, but python3.12 needs venv to work properly, and Ubuntu asks for this package to be installed in the system to create venv.

FYI I hacked test-run with --break-system-dependencies and clang-format job runs a lot faster https://github.com/llvm/llvm-project/actions/runs/18064896361/job/51406365488#logs (skipping 1min long clang-format installation). Just don't look at "Initialize containers" taking 6min, it usually takes 15-20sec


Full diff: https://github.com/llvm/llvm-project/pull/161024.diff

1 Files Affected:

  • (modified) .github/workflows/containers/github-action-ci/Dockerfile (+1)
diff --git a/.github/workflows/containers/github-action-ci/Dockerfile b/.github/workflows/containers/github-action-ci/Dockerfile
index 1d3f5f9c35d7f..dc0c9cabc7f01 100644
--- a/.github/workflows/containers/github-action-ci/Dockerfile
+++ b/.github/workflows/containers/github-action-ci/Dockerfile
@@ -62,6 +62,7 @@ RUN apt-get update && \
     # Having a symlink from python to python3 enables code sharing between
     # the Linux and Windows pipelines.
     python3-pip \
+    python3-venv \
     file \
     tzdata \
     python-is-python3 && \

Copy link
Contributor

@boomanaiden154 boomanaiden154 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

I think we want to eventually move to separate containers for the clang-format/premerge/clang-tidy workflows to trim down on space (and preinstall necessary python dependencies), but this seems fine for now, especially since the premerge container already has clang-format/clang-tidy.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants