{"record":{"id":"2fba0571c7b03363","repo":"jdx/mise","slug":"precompiled-erlang-is-not-available-reason","errorCode":null,"errorMessage":"precompiled erlang is not available: {reason}","messagePattern":"precompiled erlang is not available: (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/plugins/core/erlang.rs","lineNumber":98,"sourceCode":"    }\n\n    async fn install_kerl(&self) -> Result<()> {\n        debug!(\"Installing kerl to {}\", display_path(self.kerl_path()));\n        HTTP_FETCH\n            .download_file(\n                format!(\"https://raw.githubusercontent.com/kerl/kerl/{KERL_VERSION}/kerl\"),\n                &self.kerl_path(),\n                None,\n            )\n            .await?;\n        file::make_executable(self.kerl_path())?;\n        Ok(())\n    }\n\n    fn precompiled_unavailable(&self, reason: impl Into<String>) -> Result<Option<ToolVersion>> {\n        let reason = reason.into();\n        if Settings::get().erlang_compile(CompilePurpose::Inspect) == Some(false) {\n            bail!(\"precompiled erlang is not available: {reason}\");\n        }\n        debug!(\"{reason}\");\n        Ok(None)\n    }\n\n    fn release_tag(version: &str) -> String {\n        format!(\"OTP-{version}\")\n    }\n\n    fn lockfile_url(&self, locked: bool, tv: &ToolVersion) -> Option<String> {\n        locked_platform_url(locked, &tv.lock_platforms, &self.get_platform_key())\n    }\n\n    fn set_lockfile_info(\n        &self,\n        tv: &mut ToolVersion,\n        install: Option<&str>,\n        url: &str,","sourceCodeStart":80,"sourceCodeEnd":116,"githubUrl":"https://github.com/jdx/mise/blob/533346cc374382b41ec5ff70536252b2e96e725c/src/plugins/core/erlang.rs#L80-L116","documentation":"Erlang can be installed precompiled (Hex builds) or compiled from source. This bail fires when a precompiled build is unavailable for the requested platform/version AND the erlang_compile setting is explicitly Some(false), meaning mise is forbidden from falling back to source compilation.","triggerScenarios":"`mise install erlang@<version>` on a platform/version with no precompiled Hex build while `erlang_compile` is explicitly disabled in settings (e.g. MISE_ERLANG_COMPILE=false), so precompiled_unavailable becomes fatal instead of falling back.","commonSituations":"Users who disabled compilation for speed/CI hitting a platform gap (no Hex build for their distro/arch); CI configs that hard-set erlang_compile=false then request an unusual Erlang version.","solutions":["Enable source compilation: remove MISE_ERLANG_COMPILE=false or set erlang_compile = true in settings","Pick an Erlang version that has a precompiled build for your platform on builds.hex.pm","Change the platform/distro target (e.g. use a supported Ubuntu version) if you need precompiled","Pin a version known to have precompiled artifacts for musl-free Linux/macOS"],"exampleFix":"// before\nMISE_ERLANG_COMPILE=false mise install erlang@26.0\n// after\nmise settings set erlang_compile true\nmise install erlang@26.0","handlingStrategy":"fallback","validationCode":"# check if compilation is allowed and platform has precompiled builds\nmise settings get erlang_compile\nuname -m  # confirm arch has hex.pm builds","typeGuard":null,"tryCatchPattern":"catch (e) {\n  if (/precompiled erlang is not available/.test(String(e))) {\n    // enable erlang_compile or switch version/platform\n  }\n}","preventionTips":["Only set MISE_ERLANG_COMPILE=false if you've confirmed hex.pm has builds for your platform","Pin Erlang versions with known precompiled artifacts for your CI OS","Keep build toolchains installed even when preferring precompiled, as fallback"],"tags":["erlang","compile","platform","configuration"],"backgroundTag":"feature-not-enabled","analyzedSha":"533346cc374382b41ec5ff70536252b2e96e725c","analyzedAt":"2026-09-17T13:35:38.149Z","contentChangedAt":"2026-09-17T13:35:38.149Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}