fix(rattler_networking): retry a digest-addressed OCI blob 404 through the manifest - #2653
Open
earlybard wants to merge 1 commit into
Open
fix(rattler_networking): retry a digest-addressed OCI blob 404 through the manifest#2653earlybard wants to merge 1 commit into
earlybard wants to merge 1 commit into
Conversation
…h the manifest Pull-through caches (e.g. Amazon ECR) only import an artifact once its manifest is pulled. When a blob addressed directly by its repodata digest comes back 404, resolve the digest through the manifest and retry once. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
earlybard
force-pushed
the
fix/oci-blob-digest-404-retry
branch
from
August 9, 2026 22:39
26d1683 to
a6491e6
Compare
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Pull-through caches (e.g. Amazon ECR) only import an artifact once its manifest is pulled. When repodata already provides the package hash, the OCI middleware addresses the blob directly by digest and never touches the manifest — so on a pull-through cache the blob request 404s even though the artifact is available upstream.
This PR makes a digest-addressed blob 404 fall back to resolving the digest through the manifest (which triggers the cache import) and retrying the blob once. A 404 on the manifest path itself is still a real miss and comes back as a plain 404. The
WWW-Authenticatechallenge replay is extracted into a helper shared by both attempts, so the fallback also works when the registry re-authenticates in flight.This is the last part of #2624, following #2628 and #2651.
Fixes #2624
How Has This Been Tested?
New integration tests against ghcr.io in
oci_middleware.rs:X-Expected-Sha256for an existing package falls back to the manifest and still downloads the artifact (content hash verified)Run with
cargo nextest run -p rattler_networking oci(all 11 pass).AI Disclosure
Tools: Claude Code