wagoodman/dive · error
not implemented
Error message
not implemented
What it means
Returned by archiveResolver.Extract (dive/image/docker/archive_resolver.go:41) with a bare 'not implemented' message. Extract is meant to export a layer's contents to disk; the docker-archive resolver never implements it, so extraction from a saved tar is unsupported in this version.
Source
Thrown at dive/image/docker/archive_resolver.go:41
reader, err := os.Open(path)
if err != nil {
return nil, err
}
defer reader.Close()
img, err := NewImageArchive(reader)
if err != nil {
return nil, err
}
return img.ToImage(path)
}
func (r *archiveResolver) Build(ctx context.Context, args []string) (*image.Image, error) {
return nil, fmt.Errorf("build option not supported for docker archive resolver")
}
func (r *archiveResolver) Extract(ctx context.Context, id string, l string, p string) error {
return fmt.Errorf("not implemented")
}
View on GitHub (pinned to d6c691947f)
Solutions
- Extract manually: the saved tarball is a regular tar - untar it and then untar the layer tar inside (tar -xf image.tar; tar -xf <layer>.tar)
- Or re-load and extract via the engine: docker load -i image.tar, then run dive against docker://<image> which supports Extract
- Library callers: probe capability before calling (check for the archive resolver type or an optional interface) rather than calling blindly
Example fix
// before: assuming every resolver can extract
err := resolver.Extract(ctx, id, layerPath, dest)
// after: feature-detect first
type extractor interface{ Extract(ctx context.Context, id, l, p string) error }
if _, ok := resolver.(extractor); !ok || isArchiveResolver(resolver) {
return fmt.Errorf("source does not support extraction; untar the archive manually")
} Defensive patterns
Strategy: validation
Validate before calling
// feature-detect instead of calling Extract blindly
if src == dive.SourceDockerArchive {
return extractFromArchiveManually(tarPath, layer, dest) // plain tar extraction
}
err := resolver.Extract(ctx, id, layer, dest) Try / catch
err := resolver.Extract(ctx, id, layer, dest)
if err != nil {
if strings.Contains(err.Error(), "not implemented") {
// graceful degradation: untar the archive yourself
err = extractLayerWithTar(tarPath, layer, dest)
}
if err != nil {
return err
}
} Prevention
- Remember the docker-archive resolver supports Fetch only
- For archives, extract layers with tar directly - the format is plain tar-in-tar
- Gate Extract calls on the configured image source
When it happens
Trigger: Any Extract() call on the resolver from NewResolverFromArchive(): CLI paths that trigger layer/file extraction with --source docker-archive, or library code that uniformly calls Extract across resolvers.
Common situations: Tooling built on dive's Resolver interface that assumes all resolvers implement the full surface; users trying to export a layer from a docker-save tarball through dive instead of tar itself.
Related errors
- build option not supported for docker archive resolver
- failed to unmarshal docker config: %w
- unable to extract from image '%s': %+v
- could not find image manifest
- could not find image config
AI-assisted analysis of wagoodman/dive@d6c691947f (2026-08-15).
Data as JSON: /api/errors/283b7238b643032e.
Report an issue: GitHub.