abiosoft/colima · error

failed to read model manifest: %w

Error message

failed to read model manifest: %w

What it means

findGGUFPath materializes a model bundle: if /models/bundles/sha256/<hash>/model/model.gguf is missing it reads the OCI manifest via guest.RunOutput("docker","exec","docker-model-runner","cat","/models/manifests/sha256/<hash>"). This error means that docker exec itself failed: the manifest file does not exist or is unreadable inside the runner container (container not running, blob store garbage-collected, hash pointing at a manifest that was never created).

Source

Thrown at model/docker.go:61

}

// findGGUFPath finds the GGUF file path for a model inside the docker-model-runner container.
// It handles both Docker registry models (bundle path) and HuggingFace models (blob path via manifest).
// For models without a bundle, it creates the bundle structure by hard-linking the blob.
func findGGUFPath(guest environment.VM, modelHash string) (string, error) {
	// Standard bundle path used by Docker Model Runner for all models
	bundlePath := fmt.Sprintf("/models/bundles/sha256/%s/model/model.gguf", modelHash)

	// Check if bundle already exists
	if err := guest.RunQuiet("docker", "exec", "docker-model-runner", "test", "-f", bundlePath); err == nil {
		return bundlePath, nil
	}

	// Bundle doesn't exist - read manifest to find the GGUF blob and create the bundle
	manifestPath := fmt.Sprintf("/models/manifests/sha256/%s", modelHash)
	output, err := guest.RunOutput("docker", "exec", "docker-model-runner", "cat", manifestPath)
	if err != nil {
		return "", fmt.Errorf("failed to read model manifest: %w", err)
	}

	var manifest ociManifest
	if err := json.Unmarshal([]byte(output), &manifest); err != nil {
		return "", fmt.Errorf("failed to parse model manifest: %w", err)
	}

	// Find the GGUF layer (mediaType contains "gguf")
	var blobPath string
	for _, layer := range manifest.Layers {
		if strings.Contains(layer.MediaType, "gguf") {
			if blobHash, ok := strings.CutPrefix(layer.Digest, "sha256:"); ok {
				blobPath = fmt.Sprintf("/models/blobs/sha256/%s", blobHash)
				break
			}
		}
	}

View on GitHub (pinned to c3a5f9184d)

Solutions

  1. Re-pull the model (docker model pull <name> inside colima ssh) so a fresh manifest exists
  2. Recreate the runner container: docker model start-runner, or colima's SetupOrUpdateDocker (docker model reinstall-runner)
  3. Verify the manifest exists: colima ssh -- docker exec docker-model-runner ls /models/manifests/sha256/ and compare with the hash reported by docker model inspect
  4. If the store is corrupted, remove the model (docker model rm <name>) and pull again
Defensive patterns

Strategy: validation

Validate before calling

// Before serve: confirm runner is up and the manifest exists.
func manifestExists(guest environment.VM, modelHash string) bool {
    return guest.RunQuiet("docker", "exec", "docker-model-runner",
        "test", "-f", "/models/manifests/sha256/"+modelHash) == nil
}

Try / catch

output, err := guest.RunOutput("docker", "exec", "docker-model-runner", "cat", manifestPath)
if err != nil {
    return "", fmt.Errorf("failed to read model manifest: %w (runner up? manifest at %s?)", err, manifestPath)
}

Prevention

When it happens

Trigger: Serving a model whose bundle was never created by Docker Model Runner; the docker-model-runner container is stopped/restarting so docker exec errors; modelInfo.Hash() resolves to a manifest that was pruned by disk cleanup or belongs to an older storage layout.

Common situations: Model pulled under an older Docker/Model Runner version and never migrated; VM disk pressure triggered GC of /models/manifests; runner container half-started right after colima start; retrying serve after a partially failed pull.

Related errors


AI-assisted analysis of abiosoft/colima@c3a5f9184d (2026-08-15). Data as JSON: /api/errors/51bb74baf0cfad77. Report an issue: GitHub.