Skip to content

Releases: swyddfa/esbonio

Esbonio VSCode Extension v0.92.1 - 2024-01-15

15 Jan 23:11

Choose a tag to compare

v0.92.1 - 2024-01-15

Breaking Changes

  • The following server configuration options have been removed as they are no longer required.

    • esbonio.server.installBehavior
    • esbonio.server.updateBehavior
    • esbonio.server.updateFrequency

    The language server is now bundled as part of the VSCode extension itself, so a separate installation step is no longer necessary.

    The following sphinx configuration options have been removed

    • esbonio.server.hideSphinxOutput
    • esbonio.sphinx.buildDir
    • esbonio.sphinx.builderName
    • esbonio.sphinx.confDir
    • esbonio.sphinx.doctreeDir
    • esbonio.sphinx.forceFullBuild
    • esbonio.sphinx.keepGoing
    • esbonio.sphinx.makeMode
    • esbonio.sphinx.numJobs
    • esbonio.sphinx.quiet
    • esbonio.sphinx.silent
    • esbonio.sphinx.srcDir
    • esbonio.sphinx.tags
    • esbonio.sphinx.verbosity
    • esbonio.sphinx.warningIsError

    The Sphinx application instance is now launched using a standard sphinx-build command line provided through the esbonio.sphinx.buildCommand option, so individual options are no longer necessary.
    Note: The esbonio.sphinx.configOverrides option has been preserved as it can be easier to use than the equivalent command line options.

    (#619)

  • The minimum required VSCode version is now 1.82.0 (#666)

Enhancements

  • The following server configuration values have been added

    • esbonio.server.enableDevTools: Enable integration with lsp-devtools for the language server itself.

    The following sphinx configuration values have been added

    • esbonio.sphinx.buildCommand: Set the sphinx-build command to use when invoking the Sphinx subprocess

    • esbonio.sphinx.pythonCommand: By default, the extension will attempt to reuse the Python environment you have configured in the Python extension when invoking Sphinx.
      This option can be used to override this behavior.

    • esbonio.sphinx.cwd: The working directory from which to launch the Sphinx process

    • esbonio.sphinx.envPassthrough: A list of envrionment variables to pass through to the Sphinx process.

    • esbonio.sphinx.enableDevTools: Enable integration with lsp-devtools for the sphinx process

      • esbonio.sphinx.pythonPath: Used to override the Python packages (typically esbonio.sphinx_agent) that are injected into the Sphinx environment

    The following preview related options have been added

    • esbonio.sphinx.enableSyncScrolling: Enable support for syncronised scrolling between the editor and preview pane
    • esbonio.preview.bind: Set the network interface that the preview server binds to
    • esbonio.preview.httpPort: Set the port number the HTTP server binds to
    • esbonio.preview.wsPort: Set the port number the WebSocket server binds to

    (#626)

Misc

  • Updated the bundled version of esbonio to 1.0.0b1 (#720)

Esbonio Language Server v1.0.0b1 - 2024-01-15

15 Jan 22:40

Choose a tag to compare

v1.0.0b1 - 2024-01-15

Breaking Changes

  • Removed esbonio.lsp.spelling module, though it will be available as esbonio.ext.spelling via the esbonio-extensions package. (#583)
  • Drop Python 3.7 support (#584)
  • Drop Sphinx 4.x support (#585)

Features

  • The language server now supports reading configuration values from workspace/configuration requests and pyproject.toml files.
    When supported by the client, the server can detect and respond to changes in (most) configuration automatically - no more manually restarting the server! (#527)
  • The language server now supports workspace/symbol requests (#611)
  • Sphinx build progress is now reported using the window/workDoneProgress/create API (#659)
  • For the clients that support the pull diagnostics model, the server now supports the textDocument/diagnostic and workspace/diagnostic methods. (#689)
  • The language server can now provide completion suggestions for MyST directives. (#706)

Enhancements

  • When providing completion suggestions for directives, esbonio now takes the .. default-domain:: directive into account (#105)

Fixes

Esbonio Language Server v0.16.4 - 2024-01-11

11 Jan 19:58

Choose a tag to compare

v0.16.4 - 2024-01-11

Fixes

  • Fix ValueError thrown when the server is given invalid Position data. Invalid values will be clamped to the range permitted by the language server protocol ([0, 2147483647]) (#714)

Esbonio Language Server v0.16.3 - 2023-11-27

27 Nov 20:35

Choose a tag to compare

v0.16.3 - 2023-11-27

Fixes

  • Fix ValueError thrown when building the document symbol for a title node that only contains a role. (#685)

Esbonio Language Server v0.16.2 - 2023-10-07

07 Oct 18:27

Choose a tag to compare

v0.16.2 - 2023-10-07

This somewhat quiet release marks the end of the 0.x series as development has now shifted to focus on what will ultimately become the 1.0 release.

In fact this release includes a sneaky preview of the 1.0 version of the server - which includes support for multi-root projects! If you are feeling adventurous and want to try it out - change the command you use to launch esbonio to python -m esbonio.server

However, to set expectations there are many missing features from the preview server. The only features currently available are sphinx builds, diagnostics, document symbols and live preview/sync scrolling - but they should all work across multiple roots/projects!

See this issue for more information and if you want to submit any feedback and keep an eye out for some beta releases in the not-to-distant-future!

Enhancements

  • When creating a Sphinx application instance, the language server will now look in all workspace folders choosing the first valid configuration it finds. Failing that it will revert to its original behavior of looking in the workspaceRoot given by the client. (#467)

Fixes

  • The server will no longer fail to handle the initialize request when clients set initializationOptions to null (#586)

Misc

Esbonio VSCode Extension v0.11.0 - 2023-03-06

06 Mar 22:47

Choose a tag to compare

v0.11.0 - 2023-03-06

Features

  • It should now be possible to run the Sphinx based language server in https://vscode.dev!

    Note, that this functionality, is still experimental. To try it out, you will need to explicity set the esbonio.sphinx.confDir option to /<github-user>/<github-repo>/<path>/. For example, this project would need it to be set to /swyddfa/esbonio/docs/. (#548)

Esbonio Language Server v0.16.1 - 2023-02-18

18 Feb 14:14

Choose a tag to compare

v0.16.1 - 2023-02-18

Fixes

  • With live previews enabled, esbonio should no longer conflict with Sphinx extensions that register their own source-read handlers. (#539)

Esbonio VSCode Extension v0.10.6 - 2023-02-04

04 Feb 00:13

Choose a tag to compare

v0.10.6 - 2023-02-04

Enhancements

  • Add esbonio.server.completion.preferredInsertBehavior option. Controls how completions behave when accepted, the following values are supported.

    • replace (default)

      Accepted completions will replace existing text, allowing the server to rewrite the current line in place. This allows the server to return all possible completions within the current context. In this mode the server will set the textEdit field of a CompletionItem.

    • insert

      Accepted completions will append to existing text rather than replacing it. Since rewriting is not possible, only the completions that are compatible with any existing text will be returned. In this mode the server will set the insertText field of a CompletionItem which should work better with editors that do no support textEdits. (#471)

  • Add esbonio.server.enableDevTools option.

    This new flag indended for developers, when enabled, will wrap the language server in the lsp-devtools agent, enabling the use of some extra tooling.

    It is on the developer to ensure the required dependencies are installed. (#532)

Misc

  • Bump vscode-languageclient to 8.x (#485)

Esbonio Language Server v0.16.0 - 2023-02-04

04 Feb 00:12

Choose a tag to compare

v0.16.0 - 2023-02-04

Features

  • Add new server.completion.preferredInsertBehavior option. This allows the user to indicate to the server how they would prefer completions to behave when accepted.

    The default value is replace and corresponds to the server's current behavior where completions replace existing text. In this mode the server will set the textEdit field of a CompletionItem.

    This release also introduces a new mode insert, where completions will append to existing text rather than replacing it. This also means that only the completions that are compatible with any existing text will be returned. In this mode the server will set the insertText field of a CompletionItem which should work better with editors that do no support textEdits.

    Note: This option is only a hint and the server will not ensure that it is followed, though it is planned for all first party completion suggestions to (eventually) respect this setting. As of this release, all completion suggestions support replace and role, directive and directive option completions support insert. (#471)

Documentation

API Changes

  • CompletionContext objects now expose a config field that contains any user supplied configuration values affecting completions. (#531)

Misc

  • Drop Python 3.6 support (#400)

  • Migrate to pygls v1.0

    There are some breaking changes, but only if you use Esbonio's extension APIs, if you simply use the language server in your favourite editor you shouldn't notice a difference.

    The most notable change is the replacement of pydantic type definitions with attrs and cattrs via the new lsprotocol package. For more details see pygls' migration guide. (#484)

  • Drop support for Sphinx 3.x

    Add support for Sphinx 6.x (#523)

Esbonio Language Server v0.15.0 - 2022-12-03

03 Dec 15:25

Choose a tag to compare

v0.15.0 - 2022-12-03

Note

Unless any major bugfixes are required, this will be last version of the language server that supports Python 3.6.
v0.16.0 will include the migration to pygls v1.0 and require Python 3.7+

It will potentially also be the last version of the language server to support Sphinx v3.x, assuming that Sphinx v6.x is released on schedule

Features

  • Add initial support for synced scrolling and live previews of HTML builds. Note Both of these features rely on additional integrations outside of the LSP protocol therefore requiring dedicated support from clients.

    Synced scrolling support can be enabled by setting the server.enableScrollSync initialization option to True and works by injecting line numbers into the generated HTML which a client can use to align the preview window to the source window.

    Live preview support can be enabled by setting the server.enableLivePreview initialization option to True, the language server will then pass the contents of unsaved files for Sphinx to build. Currently clients are responsible for triggering intermediate builds with the new esbonio.server.build command, though this requirement may be removed in future. (#490 @aniketsalve22 @Ch3ri0ur )

Enhancements

  • Completion suggestions will now also be generated for the long form (:py:func:) of roles and directives in the primary and standard Sphinx domains. (#416)
  • The language server should now populate the serverInfo fields of its response to a client's initialize request. (#497)
  • The default suggest_options implementation for DirectiveLanguageFeatures should now be more useful in that it will return the keys from a directive's option_spec (#498)
  • The language server now recognises and returns DocumentLinks for image:: and figure:: directives that use http:// or https:// references for images. (#506)

Fixes

  • Fix handling of deprecation warnings in Python 3.11 (#494)

  • The language server should now correctly handle errors that occur while generating completion suggestions for a directive's options

    The language server should now show hovers for directives in the primary domain. (#498)

  • Errors thrown by DirectiveLanguageFeatures during textDocument/documentLink or textDocument/definition requests are now caught and no longer result in frustrating error banners in clients.

    The textDocument/documentLink handler for image:: and figure:: should no longer throw exceptions for invalid paths on Windows. (#506)

API Changes

  • RoleLanguageFeatures have been introduced as the preferred method of extending role support going forward. Subclasses can be implement any of the following methods

    • complete_targets called when generating role target completion items
    • find_target_definitions used to implement goto definition for role targets
    • get_implementation used to get the implementation of a role given its name
    • index_roles used to tell the language server which roles exist
    • resolve_target_link used to implement document links for role targets
    • suggest_roles called when generating role completion suggestions

    and are registered using the new Roles.add_feature() method. (#495)

Deprecated

  • The following protocols have been deprecated and will be removed in v1.0

    • TargetDefinition
    • TargetCompletion
    • TargetLink

    The following methods have been deprecated and will be removed in v1.0

    • Roles.add_target_definition_provider
    • Roles.add_target_link_provider
    • Roles.add_target_completion_provider
    • RstLanguageServer.get_roles()
    • SphinxLanguageServer.get_domain()
    • SphinxLanguageServer.get_domains()
    • SphinxLanguageServer.get_roles()
    • SphinxLanguageServer.get_role_target_types()
    • SphinxLanguageServer.get_role_targets()
    • SphinxLanguageServer.get_intersphinx_targets()
    • SphinxLanguageServer.has_intersphinx_targets()
    • SphinxLanguageServer.get_intersphinx_projects() (#495)