Skip to content

Commit

Permalink
chunked: ignore ErrLayerUnknown when creating cache
Browse files Browse the repository at this point in the history
ignore the error if the layer is being deleted while we are processing
it without a lock on the store.

Signed-off-by: Giuseppe Scrivano <[email protected]>
  • Loading branch information
giuseppe committed Sep 30, 2024
1 parent c90a35b commit e3664d5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/chunked/cache_linux.go
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,7 @@ func (c *layersCache) load() error {

// the cache file is either not present or broken. Try to generate it from the TOC.
l, err = c.createCacheFileFromTOC(r.ID)
if err != nil {
if err != nil && !errors.Is(err, storage.ErrLayerUnknown) {
logrus.Warningf("Error creating cache file for layer %q: %v", r.ID, err)
}
if l != nil {
Expand Down

0 comments on commit e3664d5

Please sign in to comment.