Skip to content

fix(memorypullcache): surface pull failures with the image ref#91

Open
Adrien Delorme (azr) wants to merge 1 commit into
agent-substrate:mainfrom
azr:azr/memorypullcache-surface-pull-errors
Open

fix(memorypullcache): surface pull failures with the image ref#91
Adrien Delorme (azr) wants to merge 1 commit into
agent-substrate:mainfrom
azr:azr/memorypullcache-surface-pull-errors

Conversation

@azr
Copy link
Copy Markdown
Contributor

Symptom

When memorypullcache.Fetch fails (network, auth, 404, ...), the log shows Cache miss ref=... followed by silence. The eventual user-visible error comes from a higher layer with no ref attached, so the actual offending image is invisible in operator logs.

Cause

remote.Image, img.Size, and io.ReadAll errors were wrapped as in remote.Image: %w (etc.) and returned without ever being logged or naming the ref.

Fix

Wrap each error with the ref and log it at WARN. Same shape as the existing surfacing in #40.

`memorypullcache.Fetch` swallowed remote.Image, img.Size, and io.ReadAll
errors into a generic wrapper (`in remote.Image: %w`) without ever
logging them or naming the image. Operators saw "Cache miss ref=..."
followed by silence, even when the pull was failing (network, auth, or
404). The eventual user-visible error came from a higher layer with no
ref attached, so the root cause was hard to identify.

Wrap each error with the ref and log it at WARN. Same shape as the
existing ategcs error-surfacing in agent-substrate#40.
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