{"record":{"id":"1cabf0a4e11948c3","repo":"oraios/serena","slug":"erlang-ls-not-found-install-from-https-github","errorCode":null,"errorMessage":"Erlang LS not found. Install from: https://github.com/erlang-ls/erlang_ls","messagePattern":"Erlang LS not found\\. Install from: https://github\\.com/erlang-ls/erlang_ls","errorType":"exception","errorClass":"RuntimeError","httpStatus":null,"severity":"error","filePath":"src/solidlsp/language_servers/erlang_language_server.py","lineNumber":41,"sourceCode":"\"\"\"\nThe character that replaces the `/` in the `name/arity` identifiers reported by Erlang LS.\n\n`#` was chosen because it cannot occur in an unquoted Erlang atom, so it can never collide with a\nreal function, type or macro name (unlike `@`, which is a legal atom character).\n\"\"\"\n\n\nclass ErlangLanguageServer(SolidLanguageServer):\n    \"\"\"Language server for Erlang using Erlang LS.\"\"\"\n\n    def __init__(self, config: LanguageServerConfig, repository_root_path: str, solidlsp_settings: SolidLSPSettings):\n        \"\"\"\n        Creates an ErlangLanguageServer instance. This class is not meant to be instantiated directly.\n        Use LanguageServer.create() instead.\n        \"\"\"\n        self.erlang_ls_path = shutil.which(\"erlang_ls\")\n        if not self.erlang_ls_path:\n            raise RuntimeError(\"Erlang LS not found. Install from: https://github.com/erlang-ls/erlang_ls\")\n\n        if not self._check_erlang_installation():\n            raise RuntimeError(\"Erlang/OTP not found. Install from: https://www.erlang.org/downloads\")\n\n        super().__init__(\n            config,\n            repository_root_path,\n            ProcessLaunchInfo(cmd=[self.erlang_ls_path, \"--transport\", \"stdio\"], cwd=repository_root_path),\n            \"erlang\",\n            solidlsp_settings,\n        )\n\n        # Add server readiness tracking like Elixir\n        self.server_ready = threading.Event()\n\n        # Set generous timeout for Erlang LS initialization\n        self.set_request_timeout(120.0)\n","sourceCodeStart":23,"sourceCodeEnd":59,"githubUrl":"https://github.com/oraios/serena/blob/7fcbca7e62555ec2287ddb2f083caee805848ea6/src/solidlsp/language_servers/erlang_language_server.py#L23-L59","documentation":"The Erlang language server wrapper locates the erlang_ls executable via shutil.which at construction time. If it is not on PATH, __init__ raises RuntimeError pointing to the erlang-ls project for installation instructions — Serena does not manage this binary automatically.","triggerScenarios":"Creating an ErlangLanguageServer instance (via LanguageServer.create) on a system where `erlang_ls` cannot be found on PATH — it was never installed, installed outside PATH, or installed under a different binary name (e.g., erlang_ls vs erlang_ls.exe).","commonSituations":"Erlang installed via apt but erlang-ls never installed; erlang-ls built from source and not copied to PATH; IDE launching Serena with a different PATH than your shell.","solutions":["Install erlang-ls: https://github.com/erlang-ls/erlang_ls (build with `make && make install` or your package manager)","Verify with: which erlang_ls (in the same environment that runs Serena)","If built from source, copy/symlink the binary to a directory on PATH (e.g., ~/.local/bin)","Fix PATH for the process launching Serena if it differs from your shell"],"exampleFix":"// before\n$ which erlang_ls   # not found\n// after\n$ git clone https://github.com/erlang-ls/erlang_ls && cd erlang_ls\n$ make && make install\n$ which erlang_ls\n/usr/local/bin/erlang_ls\n","handlingStrategy":"validation","validationCode":"import shutil\ndef erlang_ls_available() -> bool:\n    return shutil.which(\"erlang_ls\") is not None","typeGuard":"def has_erlang_ls() -> bool:\n    import shutil\n    return shutil.which(\"erlang_ls\") is not None","tryCatchPattern":"try:\n    server = LanguageServer.create(LanguageServerId.ERLANG, ...)\nexcept RuntimeError as e:\n    if \"Erlang LS not found\" in str(e):\n        logger.error(\"Install erlang-ls: https://github.com/erlang-ls/erlang_ls\")","preventionTips":["Install erlang-ls alongside Erlang in dev containers and CI","Add erlang_ls install to environment bootstrap scripts","Verify `which erlang_ls` when PATH differs between shell and IDE","Keep the binary in a stable PATH directory like /usr/local/bin or ~/.local/bin"],"tags":["erlang","missing-dependency","path","language-server"],"backgroundTag":"missing-dependency-on-path","analyzedSha":"7fcbca7e62555ec2287ddb2f083caee805848ea6","analyzedAt":"2026-08-29T00:04:09.619Z","schemaVersion":2},"datasetVersion":"2026-08-29T02:17:18.158Z"}