Skip to content

Include package architecture in the pinning key #193

Open
aszady wants to merge 3 commits into
rmohr:mainfrom
aszady:pin.bestkey
Open

Include package architecture in the pinning key #193
aszady wants to merge 3 commits into
rmohr:mainfrom
aszady:pin.bestkey

Conversation

@aszady
Copy link
Copy Markdown
Contributor

@aszady aszady commented Mar 16, 2026

The pinning logic prevents the discovery of similar packages,
effectively freezing the set of involved packages within a given package name
to the ones that match requests in the packages argument to the Resolve.

Previously, the pinning mechanism used the package name as its sole key.
When a user requested a specific architecture for a package, the resolver was artificially blocked from discovering other architectures of that exact same package.
This occurred even when those alternative architectures were mandated by standard dependency relations, effectively breaking the resolution graph for multilib or cross-compiled environments.

This change replaces the raw package name with the installation key,
which incorporates both the name and the architecture, as the primary domain for pinning.
Pinning will still prevent discovering alternative versions (if a particular version was explicitly requested).

This also matches more closely the dnf behaviour.

aszady added 3 commits March 16, 2026 18:06
The pinning logic prevents the discovery of similar packages,
effectively freezing the set of involved packages within a given package name
to the ones that match requests in the `packages` argument to the `Resolve`.

Previously, the pinning mechanism used the package name as its sole key.
When a user requested a specific architecture for a package, the resolver was artificially blocked from discovering other architectures of that exact same package.
This occurred even when those alternative architectures were mandated by standard dependency relations, effectively breaking the resolution graph for multilib or cross-compiled environments.

This change replaces the raw package name with the installation key,
which incorporates both the name and the architecture, as the primary domain for pinning.
Pinning will still prevent discovering alternative versions (if a particular version was explicitly requested).

This also matches more closely the `dnf` behaviour.
@github-actions
Copy link
Copy Markdown

⚠️ Optional job e2e-bzlmod-toolchain-circular-dependencies failed ⚠️

  • exit status: 1

@aszady aszady marked this pull request as ready for review March 16, 2026 20:31
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.

1 participant