Commit Graph
71 Commits
Author SHA1 Message Date
Dominik Jain d2cf18ddcb Refactoring: Rename Language to LanguageServerId
This resolves a long-standing naming issue in Serena & SolidLSP.
2026-07-22 20:55:36 +02:00
Tyce Herrman 96ee9b65e2 Add BasedPyright as alternative LSP for Python (#1705) 2026-07-21 20:11:32 +02:00
Dominik Jain ba7cdffc02 FindReferencingSymbolsTool: Limit file system sync to the necessary case
(i.e. no full symbol search), adding tests that specifically test the tool path
2026-07-21 13:10:21 +02:00
weiconghe 9825316c23 feat: add QML language support via Qt's qmlls (#1635) 2026-07-13 13:54:23 +02:00
Dominik Jain c904efed5e SolidLSP: Allow workspace folders to be flexibly configured across all language servers
that use the newly introduced InitializeParamsBuilder

- Add new configuration option `ls_workspace_folders` to allow indexed source folders to be specified
  explicitly. In monorepos, this allows the set of indexed folders to be restricted to a subset of
  the repository. #1627
- Rename configuration option `additional_workspace_folders` to `ls_additional_workspace_folders`
  and support the option across all language servers that use an InitializeParamsBuilder
  (previously limited strictly to the TypeScript server).
  Moved the option from SolidLSPSettings to LanguageServerConfig, where it belongs.

Apply InitializeParamsBuilder in TypeScriptLanguageServer and its subclasses.
2026-07-03 01:05:40 +02:00
Michael Panchenko ad7f65ef13 CI: improve distribution of cases to batches (GH offers limited concurrency)
See https://docs.github.com/en/actions/reference/limits#job-concurrency-limits-for-github-hosted-runners
2026-06-28 19:04:31 +02:00
Michael Panchenko 0143479621 Tests: centralized test enabling logic, better parallelization in CI
Removing some heavy toolchains from windows/macos run (they will be tested only in the job based off the maximal docker image)
2026-06-28 17:47:36 +02:00
wangzhe 6e7f0e648d Add pyrefly as alternative lsp for python 2026-06-28 20:53:39 +08:00
Fabio Capucci 91a18eb465 add phpantom lsp for php (#1554) 2026-06-28 14:46:27 +02:00
BBPandKoscheiiB 5d44d017c8 feat(solidlsp): add LaTeX language server via texlab (#1600)
Register the LATEX language (.tex/.bib/.sty/.cls) backed by texlab,
downloaded as a sha256-verified single-binary from GitHub Releases
(v5.25.1) across macOS/Linux/Windows. Document symbols expose the
sectioning hierarchy; definitions/references cover labels and citations.

Includes a smoke-test fixture repo and basic document-symbol tests.

Co-authored-by: KoscheiiB <KoscheiiB@users.noreply.github.com>
2026-06-25 11:21:39 +02:00
Edward Muller ffd5dfd3e7 Add CUE language support via cue lsp (#1474) 2026-05-18 22:12:40 +02:00
Eduardo Magalhães 04630c1abb Add Svelte support (#1457)
Uses svelte LS and typescript LS as companion server
2026-05-14 12:52:34 +02:00
Dr. Dominik Jain da5783a670 Merge pull request #1466 from oraios/lsp-transport
Refactor LanguageServerProcess, separating the communication interface from the concrete implementation
2026-05-11 16:29:54 +02:00
Данилов Роман fb9c822178 feat: add BSL (1C:Enterprise) language server support (#1430)
Required bumping of java to 21 in CI
2026-05-11 10:09:51 +02:00
Dominik Jain 89d786f799 SolidLanguageServer: Rename method start_server to start_server_context for clarity and apply it in conftest 2026-05-11 09:52:53 +02:00
Vitalijs Kuprins 249f6b07f9 Add Ada / SPARK language support via AdaCore Ada Language Server (#1461)
Introduces Language.ADA backed by AdaCore's Ada Language Server (ALS),
the standard LSP-compliant server for Ada — and SPARK, since both share
the .ads/.adb file extensions and ALS distinguishes SPARK by source-level
pragmas/aspects rather than by file type.

ALS is auto-downloaded from AdaCore's GitHub releases (linux-x64/arm64,
darwin-x64/arm64, win32-x64) using the LanguageServerDependencyProviderSinglePath
pattern, with SHA256 verification per-platform. Users can override the
downloaded binary by setting ls_specific_settings.ada.ls_path to a
pre-installed ada_language_server (e.g. from Alire, GNAT Studio, or the
VS Code Ada extension).

Test repo is a minimal multi-file GNAT project (default.gpr, helper.ads,
helper.adb, main.adb). Tests modelled on test_php_basic.py: ls_running,
find_definition (within/across), find_references (within/across),
find_symbol, document_symbols, hierarchical document symbols,
bare-symbol-name sanity check.
2026-05-09 17:49:12 +02:00
0e3f665976 Cpp extensions (#1451)
* Add more cpp extensions

* Allow FilenameMatcher to be case insensitive
---------

Co-authored-by: Darin Morrison <darinmorrison@gmail.com>
Co-authored-by: silvanshade <silvanshade@users.noreply.github.com>
Co-authored-by: MischaPanch
2026-05-06 19:04:36 +02:00
3122384822 feat: Add Angular, HTML, and SCSS / Sass language servers (#1439)
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Co-authored-by: Pavlo Basanets <Pavlo_Basanets@epam.com>
2026-05-05 14:33:51 +02:00
Michael Panchenko 64e604630e Merge branch 'main' into feature/cross-package-typescript-references
# Conflicts:
#	CHANGELOG.md
#	src/solidlsp/ls.py
2026-05-04 14:26:20 +02:00
meir lixenbrgandClaude Opus 4.6 34575f9898 Add support for additional_workspace_folders, currently only for TS
The TypeScript language server was initialized with a single workspace folder,
so tsserver could not discover references across sibling packages in a monorepo.

This adds an `additional_workspace_folders` setting in
`ls_specific_settings` that accepts a list of directory paths.
Each folder is registered as an LSP workspace folder during initialization,
and a representative .ts file is opened from each to trigger tsserver project
loading. This enables `find_referencing_symbols` and `request_references` to
return results from across package boundaries.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-05-04 14:22:20 +02:00
Michael Panchenko 940bbb31de Restructured serena_agent tests, reifying the cases
Removed some cases (haxe, msl) during cherry pick due to conflicts. We don't need to cover these languages in this test
2026-04-29 23:52:26 +02:00
Michael Panchenko c55e0c900e Diagnostics, implementation and definition tools (WIP) 2026-04-29 23:52:26 +02:00
ab67ecab3b feat: add mSL (mIRC Scripting Language) support (#1315)
* feat: add mSL (mIRC Scripting Language) support

Add language server support for mIRC Scripting Language (.mrc files).
mSL is used in mIRC and AdiIRC IRC clients for scripting bots, games,
and automation.

The implementation uses a custom Python-based LSP server (pygls) that
parses aliases, events, menus, dialogs, and CTCP handlers. Dependencies
(pygls, lsprotocol) are installed in an isolated venv on first use.

Includes test repo, integration tests, and documentation updates.

* style: apply ruff formatting to msl_language_server.py

* fix: remove INITIALIZE handler that crashes pygls 2.x

pygls 2.x handles the initialize request internally. Overriding
it via @server.feature(lsp.INITIALIZE) causes the LSP subprocess
to crash. Removing the handler lets pygls auto-advertise capabilities
based on registered features (document_symbol, workspace_symbol).

* fix: update embedded LSP script for pygls 2.x

pygls 2.x moved LanguageServer from pygls.server to pygls.lsp.server.
Update import and bump requirement from pygls>=1.3.0 to pygls>=2.0.0.

* refactor: ship mSL LSP as package module, not runtime disk write

Per maintainer feedback: the mSL LSP is a Python script, so it should
ship as a module inside the package rather than being written to disk
at runtime.

Changes:
- Extract embedded LSP script to msl_lsp_server.py (proper module)
- Simplify MslLanguageServer: remove venv creation, disk writes,
  _create_msl_lsp_files(). DependencyProvider now just returns
  sys.executable and launches the sibling module directly.
- Add pygls>=2.0.0 and lsprotocol>=2023.0.0 to pyproject.toml deps

* fix: regenerate uv.lock after upstream v1.1.0 merge

* feat(msl): add references, definitions, and expand test coverage

- Add textDocument/references handler for cross-file alias reference finding
- Add textDocument/definition handler for go-to-definition support
- Handle $ prefix on cursor position for mSL identifiers
- Fix pre-existing mypy error in agent.py (dict[str, object] -> dict[str, str | int])
- Add MSL to _LANGUAGE_PYTEST_MARKERS in conftest.py
- Add MSL parametrized cases to test_find_symbol_stable and test_find_symbol_references_stable
- Expand test repo with cross-file reference examples (main.mrc <-> utils.mrc)
- Add within-file and cross-file reference tests to test_msl_basic.py
- Update docs and CHANGELOG to reflect expanded capabilities

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* style: apply ruff formatting to msl_lsp_server.py

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix(msl): add hover handler, fix cross-file references via filesystem scan

Root causes of 4 CI test failures:
- textDocument/hover was not implemented (test_find_symbol_stable needs it)
- references/workspace_symbol/definition only searched opened documents,
  missing files not explicitly opened by the client
- pygls.uris.to_fs_path returns lowercase drive letters on Windows,
  causing URI mismatch with the framework's repository path comparison

Fixes:
- Add textDocument/hover handler returning definition snippets in Markdown
- Add _get_all_mrc_files() to scan workspace filesystem for all .mrc files
- Read workspace roots from server.workspace (pygls 2.x API) instead of
  broken monkey-patching of server.lsp
- Use pathlib.Path.resolve() to normalize drive letter casing on Windows
- Simplify __main__ to just server.start_io()

All 12 tests pass locally (10 solidlsp + 2 serena_agent integration).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* MSL language: removed unnecessary Dep. provider

* Changelog

* deps

---------

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-authored-by: Michael Panchenko <michael.panchenko@oraios-ai.de>
2026-04-13 08:47:51 +02:00
Tobias Jansing e9b6c0ff85 Add Haxe language support via vshaxe/haxe-language-server
Includes full setup with ls provider, tests, docs, etc.
2026-04-10 15:07:23 +02:00
Dominik Jain fac745fc7c Merge remote-tracking branch 'origin/main' into features/move_and_safe_delete 2026-04-01 19:08:17 +02:00
Michael Panchenko d30cdf8474 Fix symbol name resolution in selected LS (#1247)
Adds tests for name resolution for each language and fixes the name resolution where tests have failed.

Also:

Extends python tests to cover ty
Extends skipping conditions for several LS (but only when not in CI)
Better test output in CI
Removed a wrong python test (started failing for ty and should have failed for pyright too)
2026-04-01 16:29:00 +02:00
Michael Panchenko 3912a07fcb Conftest: added get_pytest_markers 2026-03-27 14:07:09 +01:00
Dominik Jain 65f5145ab0 Refactoring: Improve dependency structure of LanguageServerSymbolRetriever & CodeEditors
Simplify dependency injections by depending on Project instead of low-level instances
* LanguageServerSymbolRetriever(Project) - contains the instance
* LanguageServerCodeEditor(LanguageServerSymbolRetriever)
* CodeEditor(Project)

Move retrieval methods for LS manager from SerenaAgent to Project, including
the exception-based problem report
2026-03-09 23:20:45 +01:00
Alberto SimõesandDominik Jain 58efe413e3 Merge pull request #1131 from cx-alberto-simoes/feature/configurable-serena-folder-location
feat: add configurable project_serena_folder_location setting

Add a new `project_serena_folder_location` setting to `serena_config.yml` that allows configuring where the per-project `.serena` data folder (memories, caches) is stored, with `$projectDir` and `$projectFolderName` placeholder support (default: `$projectDir/.serena`, preserving current behavior).

Resolves #1123

Co-authored-by: Dominik Jain <dominik.jain@oraios-ai.de>
2026-03-05 21:09:13 +01:00
Dominik Jain 1af824c025 Project: Make SerenaConfig compulsory, simplifying LanguageServerManager creation 2026-03-01 00:50:24 +01:00
Dominik Jain 558caa0ad5 Disable Phpactor tests in Windows CI #1039 2026-02-14 14:20:25 +01:00
Dominik Jain a72ca90358 Merge pull request #996 from takeokunn/feature/add-ignore_path-system-global
SerenaConfig: Add system-global ignored_paths for cross-project path exclusion
2026-02-14 13:13:43 +01:00
takeokunn 614b035621 fix(tests): auto-skip Phpactor tests if PHP is unavailable
- Add check in conftest.py to disable PHP_PHPACTOR tests when php binary
  is not found
- Refactor test_php_basic.py to use dynamic PHP server list based on
  availability
- Ensure tests for PHP_PHPACTOR are only parametrized if PHP is present
2026-02-14 17:30:59 +09:00
takeokunn 43902782fa Project.load: accept SerenaConfig instead of global_ignored_paths
Use `serena_config: SerenaConfig | None` without a default value,
requiring callers to explicitly pass the configuration.
2026-02-13 15:37:59 +09:00
takeokunn e0c2a4ff93 Merge branch 'feature/support-phpactor' of ssh://github.com/takeokunn/serena into feature/support-phpactor
# Conflicts:
#	test/conftest.py
2026-02-08 01:08:26 +09:00
takeokunn c972380d0a fix(test): remove php_phpactor symlink and add repo alias mapping
Remove the unnecessary php_phpactor -> php symlink. Instead, add a
_LANGUAGE_REPO_ALIASES mapping in conftest.py so that variant language
servers (PHP_PHPACTOR, PYTHON_JEDI, RUBY_SOLARGRAPH) resolve to their
base language's test repository without needing filesystem symlinks.

Addresses review comment on PR #1002.
2026-02-08 01:03:12 +09:00
Michael Panchenko fb3a0f5b17 Removed try-except around sensai import [ci skip] 2026-02-01 20:18:47 +07:00
Azraf Nahian 71a6f1ff82 CCLS Support added (#975)
Also added a test suite for both clangd and ccls
2026-02-01 20:01:51 +07:00
Roman Nikulenkov 71d23277da feat(gopls): support gopls_settings via ls_specific_settings
- Forward ls_specific_settings.go.gopls_settings to gopls as LSP initializationOptions (JSON-validated)
- Add cache context fingerprinting so persisted symbol caches are invalidated when Go build context changes (e.g. buildFlags, GOFLAGS, GOOS, GOARCH, CGO_ENABLED)
- Add build-tag fixtures + tests covering tag-dependent symbols and cache invalidation
- Document ls_specific_settings + Go example in configuration docs
2026-01-05 15:58:43 +03:00
Dominik Jain 7b287fa602 Allow Serena home directory to be overridden with SERENA_HOME env var,
defining the relevant path variables in SerenaPaths
2025-12-07 13:39:08 +01:00
Dominik Jain 01ec8465fb Try to re-enable further language tests #788 2025-12-06 13:26:23 +01:00
Dominik Jain cec8ff7a55 Change test log level to INFO 2025-12-06 12:51:53 +01:00
Dominik Jain 118365e96a Change project test fixture to scope 'module' and ensure shutdown
to avoid resource leakage (LS instances accumulating)
2025-12-06 12:51:53 +01:00
Dominik Jain e56f1d44a1 Increase LS shutdown timeout in tests to 5s 2025-12-06 00:03:29 +01:00
Dominik Jain 7de68c09c3 Improve handling of languages for which tests are disabled
adding Clojure to list of disabled languages (tests appear to fail randomly)
2025-12-05 20:46:03 +01:00
Dominik Jain 43001eca68 Attempt to fix Ubuntu CI failure by improving LS lifecycle management in tests #788 2025-12-05 14:34:51 +01:00
Dominik Jain b046f2cb24 Skip SerenaAgent tests using Java in CI #788 2025-12-05 02:27:17 +01:00
Dominik Jain 82d495b2a6 Remove LanguageServerLogger
Resolves #745
2025-11-20 21:33:37 +01:00
Dominik Jain 78be9c87fe Fix Solid-LSP project cache path using hard-coded path element '.serena'
(move to SolidLSPSettings instead)
2025-09-01 22:01:14 +02:00
Dominik Jain f2d81812c7 Apply formatter 2025-08-06 20:58:14 +02:00