{"record":{"id":"19aeb040aca91389","repo":"Budibase/budibase","slug":"errmsg","errorCode":null,"errorMessage":"${errMsg}","messagePattern":"\\$\\{errMsg\\}","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"packages/server/src/api/controllers/plugin/github.ts","lineNumber":95,"sourceCode":"    throw new Error(\"Github latest release url not found\")\n  }\n\n  try {\n    path = await downloadUnzipTarball(\n      pluginLastReleaseTarballUrl,\n      pluginName,\n      headers\n    )\n    return await getPluginMetadata(path)\n  } catch (err: any) {\n    if (path) {\n      deleteFolderFileSystem(path)\n    }\n    let errMsg = err?.message || err\n    if (errMsg === \"unexpected response Not Found\") {\n      errMsg = \"Github release tarball not found\"\n    }\n    throw new Error(errMsg)\n  }\n}\n","sourceCodeStart":77,"sourceCodeEnd":98,"githubUrl":"https://github.com/Budibase/budibase/blob/a81a902e9a8fe55b467d106765f6638f12e35c49/packages/server/src/api/controllers/plugin/github.ts#L77-L98","documentation":"Catch-all handler for the tarball download/unzip/metadata phase of githubUpload. It rethrows the underlying error's message, mapping the specific string 'unexpected response Not Found' to 'Github release tarball not found'. Any failure during downloadUnzipTarball or getPluginMetadata surfaces through here.","triggerScenarios":"The tarball download 404s (asset deleted), the archive fails to unzip, or getPluginMetadata cannot find/parse plugin.json / schema.json in the extracted directory.","commonSituations":"Release asset removed after tagging; malformed or corrupted tarball; plugin repo missing required metadata files (schema.json/plugin.json) in dist; network interruption mid-download.","solutions":["Confirm the tarball asset URL is downloadable (curl -I the browser_download_url)","Verify the plugin archive contains valid plugin.json and schema.json","Check the exact errMsg in the thrown error for the root cause (download vs metadata)","Re-publish the release with a complete, valid tarball"],"exampleFix":"// plugin repo structure\n// before (missing metadata)\n//   dist/\n//     index.js\n// after\n//   dist/\n//     index.js\n//     plugin.json\n//     schema.json","handlingStrategy":"try-catch","validationCode":"const head = await fetch(assetUrl, { method: 'HEAD' })\nif (head.status !== 200) throw new Error('Release tarball asset is not downloadable')","typeGuard":null,"tryCatchPattern":"try {\n  await installPlugin({ source: 'GITHUB', url })\n} catch (err) {\n  if (err.message === 'Github release tarball not found') {\n    console.error('Release asset 404 — republish the release')\n  } else {\n    console.error('Plugin metadata invalid:', err.message)\n  }\n}","preventionTips":["Validate the plugin archive contains plugin.json and schema.json before publishing","Ensure the release asset is not deleted or replaced with a broken upload","Inspect the propagated errMsg to distinguish download vs metadata failures","Test install with the exact tarball locally before publishing"],"tags":["download","plugin","tarball"],"backgroundTag":"plugin-tarball-download-failed","analyzedSha":"a81a902e9a8fe55b467d106765f6638f12e35c49","analyzedAt":"2026-08-29T01:03:10.972Z","schemaVersion":2},"datasetVersion":"2026-08-29T02:17:18.158Z"}