{"record":{"id":"ff3a3611a7a15b50","repo":"denoland/deno","slug":"no-ci-runs-found-for-pr-pr-number-the-pr-may-n","errorCode":null,"errorMessage":"No CI runs found for PR #{pr_number}. The PR may not have been pushed yet, CI hasn't started, or CI hasn't run on the latest commit yet.","messagePattern":"No CI runs found for PR #(.+?)\\. The PR may not have been pushed yet, CI hasn't started, or CI hasn't run on the latest commit yet\\.","errorType":"exception","errorClass":"AnyError","httpStatus":null,"severity":"error","filePath":"cli/tools/upgrade.rs","lineNumber":708,"sourceCode":"        \"databaseId,headSha\",\n        \"-q\",\n        &jq_filter,\n      ])\n      .output()\n      .context(\"failed to query CI runs by branch\")?;\n\n    if branch_runs.status.success() {\n      let ids = String::from_utf8_lossy(&branch_runs.stdout);\n      for id in ids.trim().lines() {\n        if !id.is_empty() {\n          all_run_ids.push(id.to_string());\n        }\n      }\n    }\n  }\n\n  if all_run_ids.is_empty() {\n    bail!(\n      \"No CI runs found for PR #{pr_number}. \\\n       The PR may not have been pushed yet, CI hasn't started, \\\n       or CI hasn't run on the latest commit yet.\"\n    );\n  }\n\n  // Try each run to find one with our artifact\n  let temp_dir =\n    tempfile::TempDir::new().context(\"failed to create temporary directory\")?;\n  let download_dir = temp_dir.path();\n\n  let mut downloaded = false;\n  for run_id in &all_run_ids {\n    // Try release build first, then debug\n    for name in [&artifact_name, &debug_artifact_name] {\n      log::info!(\n        \"{}\",\n        colors::gray(format!(\"Trying run {run_id}, artifact \\\"{name}\\\"...\"))","sourceCodeStart":690,"sourceCodeEnd":726,"githubUrl":"https://github.com/denoland/deno/blob/9ad36f7a2cce60488e6ec52283efb32efddaf93a/cli/tools/upgrade.rs#L690-L726","documentation":"To find a downloadable binary, Deno lists GitHub Actions runs for the PR's head SHA and its branch and collects run IDs; this error means both queries returned nothing. In other words the upgrade logic has no CI run to inspect for artifacts. It is usually a timing issue: the PR was just pushed or its latest commit has not started CI yet.","triggerScenarios":"`deno upgrade --pr <n>` immediately after a PR is opened or after a new commit is pushed, before any workflow starts; PRs from forks without the required workflows; workflows disabled or skipped for the head commit; all_run_ids left empty at cli/tools/upgrade.rs:708.","commonSituations":"Impatiently upgrading right after a maintainer pushes a fix; PRs opened from forks where CI must be approved first; GitHub incidents delaying workflow startup; draft PRs with skipped builds.","solutions":["Wait for CI to start and finish on the PR's latest commit, then re-run `deno upgrade --pr <n>`.","Open the PR page and confirm checks are actually running on the newest commit (not a stale SHA).","If CI was skipped or needs approval (fork PRs), trigger/approve the workflow first.","As a workaround, build the PR branch locally or install from a release/branch that already has artifacts."],"exampleFix":null,"handlingStrategy":"retry","validationCode":"sha=$(gh pr view 12345 --repo denoland/deno --json headRefOid -q .headRefOid)\nuntil [ -n \"$(gh run list --repo denoland/deno --commit \"$sha\" --limit 1 -q '.[].databaseId' 2>/dev/null)\" ]; do\n  echo \"waiting for CI…\"; sleep 60\nend\ndeno upgrade --pr 12345","typeGuard":null,"tryCatchPattern":"for i in 1 2 3; do deno upgrade --pr 12345 && break || sleep 120; done","preventionTips":["Only install from a PR after its checks page shows a running/completed build on the head commit.","Automate with a wait-for-run-id loop instead of upgrading immediately after push.","For fork PRs, approve/trigger the required workflows first."],"tags":["upgrade","pr-build","ci","github-actions","timing"],"backgroundTag":"ci-run-not-found","analyzedSha":"9ad36f7a2cce60488e6ec52283efb32efddaf93a","analyzedAt":"2026-08-20T13:07:44.778Z","schemaVersion":2},"datasetVersion":"2026-08-31T09:17:48.483Z"}