{"record":{"id":"6f24b80f8bc6628e","repo":"jdx/mise","slug":"erlang-does-not-yet-support-refs","errorCode":null,"errorMessage":"erlang does not yet support refs","messagePattern":"erlang does not yet support refs","errorType":"panic","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/plugins/core/erlang.rs","lineNumber":577,"sourceCode":"            .unwrap_or(\"Erlang/OTP source\");\n        ctx.pr.set_message(format!(\"Downloading {display_name}\"));\n        if !source_path.exists() {\n            HTTP.download_file(source_url, &source_path, Some(ctx.pr.as_ref()))\n                .await?;\n        }\n        self.verify_checksum(ctx, &mut tv, &source_path)?;\n\n        let kerl_base_dir = self.kerl_base_dir();\n        let kerl_source_path = kerl_base_dir\n            .join(\"archives\")\n            .join(format!(\"{}.tar.gz\", Self::release_tag(&tv.version)));\n        file::create_dir_all(kerl_source_path.parent().unwrap())?;\n        file::copy(&source_path, &kerl_source_path)?;\n\n        file::remove_all(tv.install_path())?;\n        match &tv.request {\n            ToolRequest::Ref { .. } => {\n                unimplemented!(\"erlang does not yet support refs\");\n            }\n            _ => {\n                let mut cmd = cmd!(\n                    self.kerl_path(),\n                    \"build-install\",\n                    &tv.version,\n                    &tv.version,\n                    tv.install_path()\n                )\n                .env(\"MAKEFLAGS\", format!(\"-j{}\", num_cpus::get()));\n                for (key, value) in source_build_kerl_env(tv.install_env(), &kerl_base_dir) {\n                    cmd = match value {\n                        Some(value) => cmd.env(key, value),\n                        None => cmd.env_remove(key),\n                    };\n                }\n                cmd.run()?;\n            }","sourceCodeStart":559,"sourceCodeEnd":595,"githubUrl":"https://github.com/jdx/mise/blob/533346cc374382b41ec5ff70536252b2e96e725c/src/plugins/core/erlang.rs#L559-L595","documentation":"The Erlang core plugin cannot install from a git ref: its install path downloads a tagged OTP release tarball (via kerl), and there is no mechanism to map an arbitrary ref/branch/commit to a buildable source archive, so it refuses during install_via_kerl.","triggerScenarios":"Thrown at src/plugins/core/erlang.rs:577 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Pin erlang to a released OTP version, e.g. `mise use erlang:27.1`","List available versions with `mise ls-remote erlang`","For a custom build, compile OTP manually and point mise at it via a path install (`erlang:path:...`)"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"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"}