ipfs/kubo · error

error opening zip reader: %w

Error message

error opening zip reader: %w

What it means

Raised by unpackZip when zip.OpenReader fails to open the migrations archive at arcPath; the wrapped error usually indicates the file is missing, unreadable, or not a valid zip archive, so no entries (including the expected binary) can be listed.

Source

Thrown at repo/fsrepo/migrations/unpack.go:71

		}

		if th.Name == lookFor {
			bin = tarr
			break
		}
	}

	if bin == nil {
		return errors.New("no binary found in archive")
	}

	return writeToPath(bin, out)
}

func unpackZip(arcPath, root, name, out string) error {
	zipr, err := zip.OpenReader(arcPath)
	if err != nil {
		return fmt.Errorf("error opening zip reader: %w", err)
	}
	defer zipr.Close()

	lookFor := root + "/" + name
	var bin io.ReadCloser
	for _, fis := range zipr.File {
		if fis.Name == lookFor {
			rc, err := fis.Open()
			if err != nil {
				return fmt.Errorf("error extracting binary from archive: %w", err)
			}

			bin = rc
			break
		}
	}

	if bin == nil {

View on GitHub (pinned to 329838acdf)

Solutions

  1. Retry the download for an intact archive
  2. Check the download directory permissions
  3. Download the asset manually if it persists
Defensive patterns

Strategy: retry

When it happens

Trigger: Thrown at repo/fsrepo/migrations/unpack.go:71 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of ipfs/kubo@329838acdf (2026-09-03). Data as JSON: /api/errors/b6980645c69025b5. Report an issue: GitHub.