mvanhorn/last30days-skill · error

engine: open %s: %w

Error message

engine: open %s: %w

What it means

Error "engine: open %s: %w" thrown in mvanhorn/last30days-skill.

Source

Thrown at mcp/internal/engine/extract.go:129

	return fs.WalkDir(src, ".", func(path string, d fs.DirEntry, err error) error {
		if err != nil {
			return err
		}
		if path == "." {
			return nil
		}
		target := filepath.Join(dst, path)
		if d.IsDir() {
			return os.MkdirAll(target, 0o755)
		}
		return copyEmbeddedFile(src, path, target)
	})
}

func copyEmbeddedFile(src fs.FS, srcPath, dst string) error {
	in, err := src.Open(srcPath)
	if err != nil {
		return fmt.Errorf("engine: open %s: %w", srcPath, err)
	}
	defer func() { _ = in.Close() }()
	if err := os.MkdirAll(filepath.Dir(dst), 0o755); err != nil {
		return fmt.Errorf("engine: ensure parent of %s: %w", dst, err)
	}
	out, err := os.OpenFile(dst, os.O_WRONLY|os.O_CREATE|os.O_TRUNC, 0o644)
	if err != nil {
		return fmt.Errorf("engine: create %s: %w", dst, err)
	}
	defer func() { _ = out.Close() }()
	if _, err := io.Copy(out, in); err != nil {
		return fmt.Errorf("engine: write %s: %w", dst, err)
	}
	return nil
}

// onceRegistry serializes first-call extraction per cache directory so the
// rename in ensureLocked happens exactly once across goroutines.

View on GitHub (pinned to c7460f6114)

Solutions

  1. This indicates a corrupt embedded filesystem in the MCP binary; reinstall or rebuild the MCP server so the embedded last30days script tree is complete.

When it happens

Trigger: Fires when the engine cannot open an embedded payload file for reading during cache extraction, indicating a corrupted binary or an unexpected missing asset.

Common situations: See trigger scenarios.


AI-assisted analysis of mvanhorn/last30days-skill@c7460f6114 (2026-08-15). Data as JSON: /api/errors/176126d8c7cec495. Report an issue: GitHub.