{"record":{"id":"b01d45bd248fbf7a","repo":"gitbutlerapp/gitbutler","slug":"failed-to-fetch-release-information-for-version-version","errorCode":null,"errorMessage":"Failed to fetch release information for version {version}. Version may not exist. HTTP {response_code}","messagePattern":"Failed to fetch release information for version (.+?)\\. Version may not exist\\. HTTP (.+?)","errorType":"http","errorClass":null,"httpStatus":null,"severity":"error","filePath":"crates/but-installer/src/release.rs","lineNumber":53,"sourceCode":"        transfer\n            .write_function(|data| {\n                response_data.extend_from_slice(data);\n                Ok(data.len())\n            })\n            .context(\"Failed to set write function\")?;\n        transfer\n            .perform()\n            .with_context(|| format!(\"Failed to fetch release information from {url}\"))?;\n    }\n\n    let response_code = easy\n        .response_code()\n        .context(\"Failed to get response code\")?;\n\n    if response_code != 200 {\n        match &config.version_request {\n            crate::config::VersionRequest::Specific(version) => {\n                bail!(\n                    \"Failed to fetch release information for version {version}. Version may not exist. HTTP {response_code}\"\n                );\n            }\n            crate::config::VersionRequest::Nightly => {\n                bail!(\"Failed to fetch nightly release information. HTTP {response_code}\");\n            }\n            crate::config::VersionRequest::Release => {\n                bail!(\"Failed to fetch release information from {url}. HTTP {response_code}\");\n            }\n        }\n    }\n\n    // Validate the effective URL after following redirects\n    // This protects against malicious redirects to untrusted domains or insecure protocols\n    let effective_url = easy\n        .effective_url()\n        .context(\"Failed to get effective URL\")?\n        .ok_or_else(|| anyhow!(\"Effective URL is missing\"))?;","sourceCodeStart":35,"sourceCodeEnd":71,"githubUrl":"https://github.com/gitbutlerapp/gitbutler/blob/58e5313667b857ef39a730e380af31816a7b1768/crates/but-installer/src/release.rs#L35-L71","documentation":"fetch_release got a non-200 HTTP status from the GitHub-style releases API while resolving a specific version request, and wraps the status into a descriptive error noting the version may not exist. The installer cannot proceed without release metadata.","triggerScenarios":"Requesting VersionRequest::Specific(\"x.y.z\") where the API responds with 404 (tag does not exist), 403 (rate limit), 5xx, etc. — any non-200 status for that version's release endpoint.","commonSituations":"Typo in the version string, requesting a version that was unpublished/deleted, GitHub API rate limiting without auth, transient GitHub outages.","solutions":["Check the exact version string exists as a release (e.g. `but` releases page or API)","Re-run after a delay if the status was 403/5xx (rate limit or transient outage)","Use a valid released version or Nightly/Release mode instead","Check for proxy/firewall interference with the API host"],"exampleFix":"// before\ninstall_with_version(\"1.32.0\")?;\n// after\ninstall_with_version(\"1.3.2\")?; // version string verified against releases","handlingStrategy":"retry","validationCode":"// verify the release exists before installing\nlet status = reqwest::Client::new()\n    .head(format!(\"https://api.github.com/repos/OWNER/REPO/releases/tags/{version}\"))\n    .send().await?.status();\nlet exists = status == reqwest::StatusCode::OK;","typeGuard":null,"tryCatchPattern":"match result {\n    Err(e) if e.to_string().contains(\"Version may not exist\") => {\n        // retry with backoff for 403/5xx; validate version string for 404\n    }\n    other => other?,\n}","preventionTips":["Validate version strings against the published tag list first","Handle GitHub API rate limits with auth tokens and backoff","Implement retry with exponential backoff for 5xx","Pin to versions confirmed to exist in your release process"],"tags":["http","api","release","versioning","network"],"backgroundTag":"http-non-200-response","analyzedSha":"58e5313667b857ef39a730e380af31816a7b1768","analyzedAt":"2026-09-18T06:50:32.052Z","contentChangedAt":"2026-09-18T06:50:32.052Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}