refactor(pypi): extract the wheel without python by aignas · Pull Request #3430 · bazel-contrib/rules_python
rickeylev
changed the title
feat(pipstar): extract the wheel without python
refactor(pypi): extract the wheel without python
github-merge-queue bot pushed a commit that referenced this pull request
Nov 23, 2025This is a small utility function to get us Python free when wheels are extracted in the repository phase. Next is to extract the wheel using `repository_ctx.extract` (#3430). Whereas patching the wheel after extracting is more involved to be done without Python because we need to rezip the wheel and that has to be done with Python for a few reasons (to stay sane). If we want to remove this, then we would have to create a `whl` file in the build phase, which could work, but will need to be an exercise for the reader. Nevertheless, this moves us towards removing any side-effects from Python interpreter, so changing the default interpreter would not cause us to refetch everything. --------- Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
With this we start extracting the wheel without Python and it becomes a requirement only when patching (we will extract the wheel without Python, patch it and then re-compress it which makes a very inefficient process). This should result in much faster executions.
aignas
marked this pull request as ready for review
github-merge-queue bot pushed a commit that referenced this pull request
Nov 25, 2025With this we start extracting the wheel without Python and it becomes a requirement only when patching (we will extract the wheel without Python, patch it and then re-compress it which makes a very inefficient process). This should result in much faster executions because we can start extracting wheels even before we fetch the entire Python toolchain and we don't need to fetch it in a wheel-only setup until we are actually building/executing tests. What is more bazel is faster in extracting everything. Work towards #2948
aignas
deleted the
aignas.pipstar.extract_whl_starlark_2
branch
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters