oraios/serena · error · RuntimeError
Failed to install pasls and no local version available
Error message
Failed to install pasls and no local version available
What it means
Raised by PascalServer's _setup_runtime_dependencies when the automatic download/install of pasls failed (API or network problem) AND no previously installed pasls executable exists locally. The server needs the pasls binary and cannot fall back to a cached version.
Source
Thrown at src/solidlsp/language_servers/pascal_server.py:760
else:
need_download = True
checksums = cls._get_checksums()
else:
log.debug(f"pasls is up to date: {local_version}")
if need_download:
if cls._atomic_install(pasls_dir, deps, checksums):
# Update metadata after successful installation
if latest_version:
cls._save_local_version(pasls_dir, latest_version)
else:
# API failed but download succeeded, record placeholder version
cls._save_local_version(pasls_dir, "unknown")
cls._update_last_check(pasls_dir)
else:
# Installation failed, use existing version if available
if not os.path.exists(pasls_executable_path):
raise RuntimeError("Failed to install pasls and no local version available")
log.warning("Update failed, using existing version")
# Update check time even if no update (avoid frequent checks)
if not need_download and cls._should_check_update(pasls_dir):
cls._update_last_check(pasls_dir)
assert os.path.exists(pasls_executable_path), f"pasls executable not found at {pasls_executable_path}"
# Ensure execute permission
try:
os.chmod(pasls_executable_path, 0o755)
except OSError:
pass # May fail on Windows, ignore
log.info(f"Using pasls at: {pasls_executable_path}")
return quote_windows_path(pasls_executable_path)
def _create_base_initialize_params(self) -> dict:View on GitHub (pinned to 7fcbca7e62)
Solutions
- Check network access/proxy settings and retry the download (ensure HTTPS to the pasls release endpoint works).
- Manually install pasls and place the executable at the expected pasls resources directory (where pasls_executable_path points), then restart.
- If a previous pasls exists elsewhere, copy it into the expected directory so the fallback check succeeds.
- Disable/avoid the update path by pre-seeding a valid local version file so the library uses the existing version instead of downloading.
Example fix
// before (offline first run)
server = PascalServer(repo_root) # download fails, no local pasls
// after
# pre-provision pasls binary at the expected location
shutil.copy("/opt/tools/pasls", expected_pasls_dir / "pasls")
os.chmod(expected_pasls_dir / "pasls", 0o755)
server = PascalServer(repo_root) Defensive patterns
Strategy: retry
Validate before calling
import os
def pasls_available(expected_path):
return os.path.exists(expected_path) Try / catch
try:
server = PascalServer(repo_root)
except RuntimeError as e:
if "Failed to install pasls" in str(e):
check_network_and_proxy()
provision_pasls_manually(expected_dir) # copy/verify a known-good pasls binary
server = PascalServer(repo_root)
else:
raise Prevention
- Pre-install pasls into the resources dir so the fallback path succeeds
- Allow outbound HTTPS to the pasls release endpoint in CI/proxies
- Cache the pasls directory between CI runs
- Retry the setup once on transient network failures
When it happens
Trigger: Instantiating PascalServer when the update-check attempts a download, the installation fails (network/API error), and pasls_executable_path does not exist on disk (never installed or deleted).
Common situations: First run on a machine with no cached pasls while the download endpoint is unreachable; offline/air-gapped environment; corporate proxy blocking the download URL; API returning an error before download completes.
Related errors
- No free ports found starting from {start_port}
- Failed to connect to Serena service at {url}: {e}
- Request to {url} timed out: {e}
- API request failed with HTTP error: {e}
- Request failed: {e}
AI-assisted analysis of oraios/serena@7fcbca7e62 (2026-08-29).
Data as JSON: /api/errors/2ba8a7e312946295.
Report an issue: GitHub.