{"record":{"id":"02399cd4bf1b1423","repo":"BoundaryML/baml","slug":"no-released-baml-artifact-is-available-for-arch-os-install","errorCode":null,"errorMessage":"no released BAML artifact is available for {arch}-{os}. Install the matching toolchain via `baml toolchain install <version>`.","messagePattern":"no released BAML artifact is available for (.+?)-(.+?)\\. Install the matching toolchain via `baml toolchain install <version>`\\.","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"baml_language/crates/baml_release/src/lib.rs","lineNumber":298,"sourceCode":"        .unwrap_or_else(|| DEFAULT_RELEASE_REPO.to_string())\n}\n\npub fn release_host_target_triple() -> Result<&'static str> {\n    #[cfg(target_env = \"musl\")]\n    const IS_MUSL: bool = true;\n    #[cfg(not(target_env = \"musl\"))]\n    const IS_MUSL: bool = false;\n\n    match (std::env::consts::OS, std::env::consts::ARCH, IS_MUSL) {\n        (\"macos\", \"aarch64\", _) => Ok(\"aarch64-apple-darwin\"),\n        (\"macos\", \"x86_64\", _) => Ok(\"x86_64-apple-darwin\"),\n        (\"linux\", \"aarch64\", true) => Ok(\"aarch64-unknown-linux-musl\"),\n        (\"linux\", \"aarch64\", false) => Ok(\"aarch64-unknown-linux-gnu\"),\n        (\"linux\", \"x86_64\", true) => Ok(\"x86_64-unknown-linux-musl\"),\n        (\"linux\", \"x86_64\", false) => Ok(\"x86_64-unknown-linux-gnu\"),\n        (\"windows\", \"x86_64\", _) => Ok(\"x86_64-pc-windows-msvc\"),\n        (\"windows\", \"aarch64\", _) => Ok(\"aarch64-pc-windows-msvc\"),\n        (os, arch, _) => anyhow::bail!(\n            \"no released BAML artifact is available for {arch}-{os}. \\\n             Install the matching toolchain via `baml toolchain install <version>`.\"\n        ),\n    }\n}\n\npub fn validate_release_target_triple(target: &str) -> Result<&str> {\n    if SUPPORTED_RELEASE_TARGETS.contains(&target) {\n        Ok(target)\n    } else {\n        anyhow::bail!(\n            \"unsupported release target `{target}`. Supported targets: {}\",\n            SUPPORTED_RELEASE_TARGETS.join(\", \")\n        )\n    }\n}\n\npub fn release_archive_filename(product: Product, version: &str, target: &str) -> String {","sourceCodeStart":280,"sourceCodeEnd":316,"githubUrl":"https://github.com/BoundaryML/baml/blob/bd85ce9dee1463ff04d27efd20531013a4ff46c1/baml_language/crates/baml_release/src/lib.rs#L280-L316","documentation":"release_host_target_triple maps the current OS/arch (and musl flag) to a released Rust target triple. If the host combination is not one of the known linux/windows x86_64/aarch64 targets, it bails with this message telling the user to install the matching toolchain manually. It guards against attempting a self-update/download on an unsupported platform.","triggerScenarios":"Calling release_host_target_triple on an OS outside {linux, windows} or an arch outside {x86_64, aarch64} — e.g. macOS, FreeBSD, armv7, riscv64 hosts.","commonSituations":"Running baml self-update inside an Alpine/FreeBSD container with an odd uname, on Raspberry Pi 32-bit, or on macOS where releases aren't published under these triples.","solutions":["Run baml on a supported target: linux or windows on x86_64 or aarch64.","Install the toolchain manually via `baml toolchain install <version>` as the message suggests.","Check `uname -m`/`uname -s` and, if a container reports an unexpected arch, use an official image for a supported arch.","Request/file support for the missing target triple upstream."],"exampleFix":"// unsupported host\n// linux-armv7 container\n// after: use a supported base image\nFROM --platform=linux/amd64 alpine:latest","handlingStrategy":"validation","validationCode":"let (os, arch) = (std::env::consts::OS, std::env::consts::ARCH);\nlet supported = matches!((os, arch),\n    (\"linux\", \"x86_64\") | (\"linux\", \"aarch64\") | (\"windows\", \"x86_64\") | (\"windows\", \"aarch64\"));\nif !supported { /* fall back to manual toolchain install */ }","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Check the supported target matrix before enabling self-update on a platform.","In containers, pin images to supported architectures (--platform=linux/amd64).","Provide a manual `baml toolchain install` path for unsupported hosts."],"tags":["platform","target-triple","unsupported-platform","self-update"],"backgroundTag":"unsupported-platform","analyzedSha":"bd85ce9dee1463ff04d27efd20531013a4ff46c1","analyzedAt":"2026-09-12T03:38:25.718Z","contentChangedAt":"2026-09-12T03:38:25.718Z","schemaVersion":2},"datasetVersion":"2026-09-14T11:17:12.474Z"}