{"record":{"id":"df2b31a1f0b816ea","repo":"hashicorp/packer","slug":"zip-v","errorCode":null,"errorMessage":"zip : %v","messagePattern":"zip : %v","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"packer/plugin-getter/plugins.go","lineNumber":850,"sourceCode":"\t\t\t\t\t\terr := fmt.Errorf(\"Error getting plugin, trying another getter: %w\", err)\n\t\t\t\t\t\terrs = multierror.Append(errs, err)\n\t\t\t\t\t\tcontinue\n\t\t\t\t\t}\n\t\t\t\t\tif _, err := tmpFile.Seek(0, 0); err != nil {\n\t\t\t\t\t\terr := fmt.Errorf(\"Error seeking beginning of temporary file for checksumming, continuing: %w\", err)\n\t\t\t\t\t\terrs = multierror.Append(errs, err)\n\t\t\t\t\t\tcontinue\n\t\t\t\t\t}\n\n\t\t\t\t\t// verify that the checksum for the zip is what we expect.\n\t\t\t\t\tif err := checksum.Checksummer.Checksum(checksum.Expected, tmpFile); err != nil {\n\t\t\t\t\t\terr := fmt.Errorf(\"%w. Is the checksum file correct ? Is the binary file correct ?\", err)\n\t\t\t\t\t\terrs = multierror.Append(errs, err)\n\t\t\t\t\t\tcontinue\n\t\t\t\t\t}\n\t\t\t\t\tzr, err := zip.OpenReader(tmpFile.Name())\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\terrs = multierror.Append(errs, fmt.Errorf(\"zip : %v\", err))\n\t\t\t\t\t\treturn nil, errs\n\t\t\t\t\t}\n\n\t\t\t\t\tvar copyFrom io.ReadCloser\n\t\t\t\t\tfor _, f := range zr.File {\n\t\t\t\t\t\tif f.Name != expectedBinaryFilename {\n\t\t\t\t\t\t\tcontinue\n\t\t\t\t\t\t}\n\t\t\t\t\t\tcopyFrom, err = f.Open()\n\t\t\t\t\t\tif err != nil {\n\t\t\t\t\t\t\terrs = multierror.Append(errs, fmt.Errorf(\"failed to open temp file: %w\", err))\n\t\t\t\t\t\t\treturn nil, errs\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak\n\t\t\t\t\t}\n\t\t\t\t\tif copyFrom == nil {\n\t\t\t\t\t\terr := fmt.Errorf(\"could not find a %q file in zipfile\", expectedBinaryFilename)\n\t\t\t\t\t\terrs = multierror.Append(errs, err)","sourceCodeStart":832,"sourceCodeEnd":868,"githubUrl":"https://github.com/hashicorp/packer/blob/eb36e3c3e48a036f3e8cc94087636ee72e1303c9/packer/plugin-getter/plugins.go#L832-L868","documentation":"Plugin installation error from InstallLatest: the downloaded temp file, which passed checksumming, could not be opened as a zip archive — the file is corrupt or truncated. This aborts the install loop immediately.","triggerScenarios":"Thrown at packer/plugin-getter/plugins.go:850 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Retry the plugin install to re-download the zip","Check disk space and network integrity if corruption repeats"],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"eb36e3c3e48a036f3e8cc94087636ee72e1303c9","analyzedAt":"2026-09-05T13:20:43.127Z","contentChangedAt":"2026-09-05T13:20:43.127Z","schemaVersion":2},"datasetVersion":"2026-09-12T17:17:11.597Z"}