oraios/serena · error · SolidLSPException
dotnet executable not found at {dotnet_exe} after installati
Error message
dotnet executable not found at {dotnet_exe} after installation What it means
After running the official dotnet-install script, install_dotnet_with_script checks that the expected dotnet executable actually exists at the target path; if not it raises SolidLSPException. This catches silent script failures where the process exits 0 but nothing was installed.
Source
Thrown at src/serena/util/dotnet.py:146
cmd = [
"bash",
str(script_path),
"--version",
version,
"--install-dir",
str(dotnet_dir),
"--runtime",
"dotnet",
"--no-path",
]
# Run the install script
log.info("Running .NET install script: %s", cmd)
result = subprocess_run(cmd, capture_output=True, text=True, check=True)
log.debug(f"Install script output: {result.stdout}")
if not dotnet_exe.exists():
raise SolidLSPException(f"dotnet executable not found at {dotnet_exe} after installation")
log.info(f"Successfully installed .NET {version} runtime to {dotnet_exe}")
return str(dotnet_exe)
except subprocess.CalledProcessError as e:
raise SolidLSPException(f"Failed to install .NET {version} runtime using install script: {e.stderr if e.stderr else e}") from e
except Exception as e:
message = f"Failed to install .NET {version} runtime: {e}"
if is_windows and isinstance(e, FileNotFoundError):
message += "; pwsh, i.e. PowerShell 7+, is required to install .NET runtime. Make sure pwsh is available on your system."
raise SolidLSPException(message) from e
View on GitHub (pinned to 7fcbca7e62)
Solutions
- Re-run the install with verbose logging and inspect the script's stdout for skipped-download reasons
- Check free disk space and write permissions for the install directory
- Manually download the runtime tarball/zip from Microsoft and extract dotnet to the expected path
- Pin a known-good dotnet-install script version or set DOTNET_ROOT explicitly
Example fix
// before cmd = [install_script, '--channel', '8.0'] // after cmd = [install_script, '--channel', '8.0', '--verbose'] # then inspect stdout and verify: test -f "$DOTNET_ROOT/dotnet"
Defensive patterns
Strategy: validation
Validate before calling
dotnet_exe = Path(install_dir) / "dotnet"
result = subprocess_run(cmd, capture_output=True, text=True)
if not dotnet_exe.exists():
print(result.stdout, result.stderr)
raise RuntimeError("install script did not produce a dotnet binary") Try / catch
try:
path = util.install_dotnet_with_script(version)
except SolidLSPException as e:
log.error("dotnet install failed: %s", e)
# fall back to manual install instructions Prevention
- Verify disk space and write permissions on the install dir before installing
- Check install script stdout for silent skip reasons (wrong arch/OS flags)
- Prefer pre-installing dotnet in the image over runtime downloads
When it happens
Trigger: The install script completes without raising (exit 0) but the dotnet binary is not present at dotnet_exe — e.g. wrong architecture/channel download, install dir mismatch, script skipped download due to disk/network issues that still exit 0.
Common situations: Restricted filesystems or read-only install directories; proxy/CDN serving an error page saved where the binary should be; mismatched OS/arch parameter passed to the install script.
Related errors
- Failed to install .NET {version} runtime: {e}
- Required .NET runtime version {self._required_version_str} n
- Failed to install .NET {version} runtime using install scrip
- dotnet not found on the system
- No supported dotnet version found. Available versions: {', '
AI-assisted analysis of oraios/serena@7fcbca7e62 (2026-08-29).
Data as JSON: /api/errors/450d334cf235b859.
Report an issue: GitHub.