{"record":{"id":"422f67a5c5d10476","repo":"astrid-runtime/astrid","slug":"method-managed-installs-follow-only-stable-use","errorCode":null,"errorMessage":"{method}-managed installs follow only stable; use a self-managed Astrid install for '{channel}'.","messagePattern":"(.+?)-managed installs follow only stable; use a self-managed Astrid install for '(.+?)'\\.","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"crates/astrid-cli/src/commands/self_update_notice.rs","lineNumber":145,"sourceCode":"        InstallMethod::Cargo => {\n            format!(\"cargo install astrid --version ={selected_version} --force\")\n        },\n        InstallMethod::SelfManaged => unreachable!(\"self-managed installs update in place\"),\n    })\n}\n\npub(super) fn handle_managed_channel(\n    method: InstallMethod,\n    channel: UpdateChannel,\n    current: &semver::Version,\n    selected: &semver::Version,\n    selected_version: &str,\n) -> anyhow::Result<bool> {\n    if !method.manages_own_binary() {\n        return Ok(false);\n    }\n    if channel != UpdateChannel::Stable {\n        bail!(\n            \"{}-managed installs follow only stable; use a self-managed Astrid install for '{}'.\",\n            method.label(),\n            channel\n        );\n    }\n    if selected == current {\n        return Ok(false);\n    }\n    let how = managed_update_command(method, current, selected, selected_version)\n        .expect(\"package-managed method has an update command\");\n    let message = if selected < current {\n        format!(\n            \"The signed stable channel rolled back v{CURRENT_VERSION} → v{selected_version}. Apply the package-managed rollback with:\\n  {how}\"\n        )\n    } else {\n        format!(\n            \"Astrid was installed via {}. Update to signed stable v{selected_version} with:\\n  {how}\",\n            method.label()","sourceCodeStart":127,"sourceCodeEnd":163,"githubUrl":"https://github.com/astrid-runtime/astrid/blob/affd8760f44190dbdfbec23403f4c4b642c33112/crates/astrid-cli/src/commands/self_update_notice.rs#L127-L163","documentation":"When the install method manages its own binary (e.g. Homebrew or cargo rather than Astrid's self-update), only the Stable channel is allowed for update notices. Selecting any other channel (beta/nightly) is rejected with guidance to use a self-managed install for prerelease channels. Package managers should not be told to install non-stable builds.","triggerScenarios":"Running `astrid self update --channel beta` (or nightly) on an install where method.manages_own_binary() is true — i.e. Astrid was installed via Homebrew/cargo — during run_self_update's managed-channel handling.","commonSituations":"Users who installed via `brew install astrid` or `cargo install` trying to switch to a prerelease channel; scripts that pass a non-stable channel unconditionally.","solutions":["Use `--channel stable` (or omit the channel) for package-manager-managed installs.","To follow beta/nightly, migrate to a self-managed install: download the official self-managed build and install it, then select the desired channel.","If you need prereleases from the package manager, request them upstream (e.g. brew tap with a beta formula)."],"exampleFix":"// before\n$ astrid self update --channel beta   # brew-managed install\nerror: homebrew-managed installs follow only stable...\n\n// after\n$ astrid self update                   # stable only for brew/cargo installs\n# or switch to a self-managed install to use beta","handlingStrategy":"validation","validationCode":"if install_method.manages_own_binary() && channel != UpdateChannel::Stable {\n    eprintln!(\"managed installs only support the stable channel\");\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Only pass --channel with self-managed installs.","Default scripts and CI to the stable channel.","Document that beta/nightly requires the self-managed installer."],"tags":["self-update","channel","package-manager","unsupported-operation"],"backgroundTag":"unsupported-enum-value","analyzedSha":"affd8760f44190dbdfbec23403f4c4b642c33112","analyzedAt":"2026-09-09T21:28:12.402Z","contentChangedAt":"2026-09-09T21:28:12.402Z","schemaVersion":2},"datasetVersion":"2026-09-17T15:17:12.973Z"}