{"record":{"id":"834c0ab01c86c93e","repo":"oven-sh/bun","slug":"buildkite-agent-artifact-download-timed-out-after","errorCode":null,"errorMessage":"buildkite-agent artifact download timed out after 120s for step '${target}'. Refusing to continue with a partial download (would silently fall back to the wrong binary).","messagePattern":"buildkite-agent artifact download timed out after 120s for step '(.+?)'\\. Refusing to continue with a partial download \\(would silently fall back to the wrong binary\\)\\.","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"scripts/runner.node.mjs","lineNumber":2750,"sourceCode":"\n  const releasePath = join(cwd, \"release\");\n  mkdirSync(releasePath, { recursive: true });\n\n  let zipPath;\n  downloadLoop: for (let i = 0; i < 10; i++) {\n    // build-bun also uploads libbun-*.a / libbun_rust.a / dep libs; only the zips are wanted here.\n    const args = [\"artifact\", \"download\", \"*.zip\", releasePath, \"--step\", target];\n    if (buildId) {\n      args.push(\"--build\", buildId);\n    }\n\n    const { error } = await spawnSafe({\n      command: \"buildkite-agent\",\n      args,\n      timeout: 120000,\n    });\n    if (error === \"timeout\") {\n      throw new Error(\n        `buildkite-agent artifact download timed out after 120s for step '${target}'. ` +\n          `Refusing to continue with a partial download (would silently fall back to the wrong binary).`,\n      );\n    }\n\n    zipPath = readdirSync(releasePath, { recursive: true, encoding: \"utf-8\" })\n      .filter(filename => /^bun.*\\.zip$/i.test(filename))\n      .map(filename => join(releasePath, filename))\n      .sort((a, b) => b.includes(\"profile\") - a.includes(\"profile\"))\n      .at(0);\n\n    if (zipPath) {\n      break downloadLoop;\n    }\n\n    console.warn(`Waiting for ${target}.zip to be available...`);\n    await new Promise(resolve => setTimeout(resolve, i * 1000));\n  }","sourceCodeStart":2732,"sourceCodeEnd":2768,"githubUrl":"https://github.com/oven-sh/bun/blob/8c5296ac459e8252d3cd702f3fbcbb0c249d95d5/scripts/runner.node.mjs#L2732-L2768","documentation":"Error \"buildkite-agent artifact download timed out after 120s for step '${target}'. Refusing to continue with a partial download (would silently fall back to the wrong binary).\" thrown in oven-sh/bun.","triggerScenarios":"Thrown at scripts/runner.node.mjs:2750 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"8c5296ac459e8252d3cd702f3fbcbb0c249d95d5","analyzedAt":"2026-08-16T08:01:58.794Z","schemaVersion":2},"datasetVersion":"2026-08-16T08:17:34.114Z"}