oraios/serena · error · FileNotFoundError

Download failed? Could not find marksman executable at {mark

Error message

Download failed? Could not find marksman executable at {marksman_executable_path}

What it means

marksman downloads its binary on first use via the deps installer. After running deps.install, the code re-checks for the executable and raises FileNotFoundError if it still does not exist, indicating the download or install layout did not produce the expected file at marksman_executable_path.

Source

Thrown at src/solidlsp/language_servers/marksman.py:140

            """Setup runtime dependencies for marksman and return the command to start the server."""
            marksman_version = self._custom_settings.get("marksman_version", DEFAULT_MARKSMAN_VERSION)
            deps = self._runtime_dependencies(marksman_version)
            dependency = deps.get_single_dep_for_current_platform()

            # legacy unversioned dir reserved for INITIAL; every other version goes into a versioned subdir
            marksman_ls_dir = (
                self._ls_resources_dir
                if marksman_version == INITIAL_MARKSMAN_VERSION
                else os.path.join(self._ls_resources_dir, f"marksman-{marksman_version}")
            )
            marksman_executable_path = deps.binary_path(marksman_ls_dir)
            if not os.path.exists(marksman_executable_path):
                log.info(
                    f"Downloading marksman from {dependency.url} to {marksman_ls_dir}",
                )
                deps.install(marksman_ls_dir)
            if not os.path.exists(marksman_executable_path):
                raise FileNotFoundError(f"Download failed? Could not find marksman executable at {marksman_executable_path}")
            os.chmod(marksman_executable_path, 0o755)
            return marksman_executable_path

        def _create_launch_command(self, core_path: str) -> list[str]:
            return [core_path, "server"]

    def __init__(self, config: LanguageServerConfig, repository_root_path: str, solidlsp_settings: SolidLSPSettings):
        """
        Creates a Marksman instance. This class is not meant to be instantiated directly.
        Use LanguageServer.create() instead.
        """
        super().__init__(
            config,
            repository_root_path,
            None,
            "markdown",
            solidlsp_settings,
        )

View on GitHub (pinned to 7fcbca7e62)

Solutions

  1. Check network/proxy access to the marksman release URL (dependency.url) and retry
  2. Manually download the marksman binary for your platform and place it at the expected path in the marksman install directory, then chmod +x
  3. Check logs for the underlying download error from deps.install and verify the URL still serves assets for your OS/arch

Example fix

# before (rely on auto-download)
ls = SolidLSP("marksman")
# after (pre-install manually)
# curl -L -o ~/.serena/language_servers/static/marksman/marksman <release-url> && chmod +x .../marksman
ls = SolidLSP("marksman")
Defensive patterns

Strategy: retry

Validate before calling

import os
marksman_dir = "<install_dir>"
exe = os.path.join(marksman_dir, "marksman")
assert os.path.exists(exe) and os.access(exe, os.X_OK), "pre-install marksman first"

Type guard

def marksman_installed(path: str) -> bool:
    return os.path.isfile(path) and os.access(path, os.X_OK)

Try / catch

try:
    ls = SolidLSP("marksman")
except FileNotFoundError as e:
    if "marksman executable" in str(e):
        manually_download_and_chmod(marksman_dir)
        ls = SolidLSP("marksman")
    else:
        raise

Prevention

When it happens

Trigger: First-run auto-install of marksman where deps.install(marksman_ls_dir) fails to place the binary (network failure, unsupported platform asset, 404 from GitHub releases, or proxy blocking the download) and the subsequent os.path.exists check fails.

Common situations: Corporate proxies or firewalls blocking GitHub downloads; marksman release assets changed for your OS/arch; disk permission problems in the install directory; offline environments.

Related errors


AI-assisted analysis of oraios/serena@7fcbca7e62 (2026-08-29). Data as JSON: /api/errors/d8a2eaac9da722c4. Report an issue: GitHub.