{"record":{"id":"6063ae60f90def29","repo":"hashicorp/packer","slug":"could-not-parse-release-w","errorCode":null,"errorMessage":"could not parse release: %w","messagePattern":"could not parse release: %w","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"packer/plugin-getter/plugins.go","lineNumber":660,"sourceCode":"\tvar errs *multierror.Error\n\tfor _, getter := range getters {\n\n\t\treleasesFile, err := getter.Get(\"releases\", GetOptions{\n\t\t\tPluginRequirement:         pr,\n\t\t\tBinaryInstallationOptions: opts.BinaryInstallationOptions,\n\t\t})\n\t\tif err != nil {\n\t\t\tif errors.Is(err, HTTPFailure) {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\terrs = multierror.Append(errs, err)\n\t\t\tlog.Printf(\"[TRACE] %s\", err.Error())\n\t\t\treturn nil, errs\n\t\t}\n\n\t\treleases, err := ParseReleases(releasesFile)\n\t\tif err != nil {\n\t\t\terr := fmt.Errorf(\"could not parse release: %w\", err)\n\t\t\terrs = multierror.Append(errs, err)\n\t\t\tlog.Printf(\"[TRACE] %s\", err.Error())\n\t\t\tcontinue\n\t\t}\n\t\tif len(releases) == 0 {\n\t\t\terr := fmt.Errorf(\"no release found\")\n\t\t\terrs = multierror.Append(errs, err)\n\t\t\tlog.Printf(\"[TRACE] %s\", err.Error())\n\t\t\tcontinue\n\t\t}\n\t\tfor _, release := range releases {\n\t\t\tv, err := goversion.NewVersion(release.Version)\n\t\t\tif err != nil {\n\t\t\t\terr := fmt.Errorf(\"could not parse release version %s. %w\", release.Version, err)\n\t\t\t\terrs = multierror.Append(errs, err)\n\t\t\t\tlog.Printf(\"[TRACE] %s, ignoring it\", err.Error())\n\t\t\t\tcontinue\n\t\t\t}","sourceCodeStart":642,"sourceCodeEnd":678,"githubUrl":"https://github.com/hashicorp/packer/blob/eb36e3c3e48a036f3e8cc94087636ee72e1303c9/packer/plugin-getter/plugins.go#L642-L678","documentation":"During InstallLatest, Packer downloads a releases file (SHA256SUM-style listing) for each configured release URL and parses it with ParseReleases(). If the file's content cannot be parsed into release entries, the error is appended to a multierror and installation continues to the next source; if all sources fail, the aggregated error is returned.","triggerScenarios":"Calling InstallLatest when ParseReleases(releasesFile) fails for a fetched releases file — the file is empty, HTML (a 404 page served with 200), or not in the expected \"checksum  filename\" format.","commonSituations":"A custom/plugin-mirror release URL serves a webpage or JSON instead of a checksums file; the GitHub release has no SHA256SUM asset; a corporate proxy intercepts the download; network issues truncate the file.","solutions":["Open the releases URL directly and confirm it serves a plain checksums file (\"<sha256>  <filename>\" per line), not HTML or JSON.","Add a proper SHA256SUM-style asset to the plugin's GitHub release, or fix the release URL configured for the plugin.","Check proxy/firewall interference (HTTP_PROXY, corporate MITM) and retry; note the multierror may contain one error per source — read all of them."],"exampleFix":"// release currently ships only binaries — add a checksums file\n$ sha256sum packer-plugin-foo_* > SHA256SUM && gh release upload v1.0.0 SHA256SUM","handlingStrategy":"retry","validationCode":"resp, err := http.Get(releasesURL)\nif err == nil {\n\tb, _ := io.ReadAll(resp.Body)\n\tfor _, line := range strings.Split(string(b), \"\\n\") {\n\t\tf := strings.Fields(line)\n\t\tif len(f) != 2 {\n\t\t\treturn fmt.Errorf(\"%s is not a checksums file\", releasesURL)\n\t\t}\n\t}\n}","typeGuard":null,"tryCatchPattern":"releases, err := ParseReleases(releasesFile)\nif err != nil {\n\tlog.Printf(\"[TRACE] source %s unusable (%v); trying next release URL\", url, err)\n\tcontinue // mirror InstallLatest's own multi-source loop\n}","preventionTips":["Every plugin GitHub release must ship a SHA256SUM-style checksums asset","Verify release URLs return raw text, not an HTML 404/proxy page","Retry transient network failures before treating a source as invalid","Inspect all errors in the returned multierror, not just the first"],"tags":["plugin-getter","release-parsing","network","plugin-install"],"backgroundTag":"unparseable-release-manifest","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"}