Skip to content

Add flit-core as wheel to pip bundle#114

Merged
ivanovac merged 1 commit into
mainfrom
add-flit-core
Jul 10, 2026
Merged

Add flit-core as wheel to pip bundle#114
ivanovac merged 1 commit into
mainfrom
add-flit-core

Conversation

@ivanovac

@ivanovac ivanovac commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

Add flit-core as wheel to pip bundle (required by pip 26.x build backend)

Problem

pip 26.x switched its build backend from setuptools to flit-core, requiring flit-core>=3.11,<4 as a build dependency. When the Python buildpack installs pip from the bundle tarball using:

pip install --no-index --find-links=/tmp/pip

pip tries to install its build dependencies from /tmp/pip, but the bundle only contained pip's own source tarball — not flit-core. This caused staging to fail with:

ERROR: Could not find a version that satisfies the requirement flit-core<4,>=3.11 (from versions: none)
ERROR: No matching distribution found for flit-core<4,>=3.11

Fix

Add flit-core>=3.11 to ExtraDeps in PipRecipe. ExtraDeps are downloaded without --no-binary :all:, so flit-core is fetched as a pre-built wheel (flit_core-x.x.x-py3-none-any.whl). This breaks the circular dependency (flit-core source requires flit-core to build) and makes it available in /tmp/pip for pip to use as its build backend.

Testing

Rebuild the pip 26.x bundle using binary-builder and verify staging a Python app with PIP_VERSION=latest succeeds on cflinuxfs4/cflinuxfs5.

Fixes: cloudfoundry/python-buildpack#1200

@ivanovac ivanovac requested a review from ramonskie July 10, 2026 12:16
@ivanovac ivanovac merged commit 65709d4 into main Jul 10, 2026
2 checks passed
@ivanovac ivanovac deleted the add-flit-core branch July 10, 2026 12:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants