Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LSP behavior depends on selection history #8422

Closed
perlinm opened this issue Sep 29, 2023 · 0 comments · Fixed by #8423
Closed

LSP behavior depends on selection history #8422

perlinm opened this issue Sep 29, 2023 · 0 comments · Fixed by #8423
Labels
C-bug Category: This is a bug

Comments

@perlinm
Copy link

perlinm commented Sep 29, 2023

Summary

I have tried two LSPs (written in different languages) for inserting snippets: github:quantonganh/snippets-ls and github:estin/simple-completion-language-server. I ran into the same issue with both, making me suspect that the issue is really with how helix talks to LSPs. I apologize in advance if that turns out to not be the case.

In short, these libraries (together with an appropriate snippet config file) let me insert a snippet with something like b-e-g-<tab> (in insert mode), which for me results in the following:
image
In this example, the LSP also makes two cursors at locations specified by the snippet.

The issue is that the (correct) behavior above seems to (incorrectly) depend on whether the cursor/selection has changed after entering insert mode. If I do not move the cursor between entering insert mode and inserting the snippet, I get
image
where the cursor is now at the end of the snippet. This behavior is the same for single-cursor snippets: whether the cursor gets placed (a) where it "should" be or (b) after the snippet depends on whether the cursor has moved after entering insert mode.

Reproduction Steps

  1. Install github:estin/simple-completion-language-server.
  2. Add the following to your ~/.config/helix/languages.toml:
[[language]]
name = "latex"
language-servers = ["texlab", "simple-completion-language-server"]

[language-server.simple-completion-language-server]
command = "simple-completion-language-server"
  1. Write the following to ~/.config/helix/snippets/latex.json:
{
  "environment": {
    "prefix": "begin",
    "body": [
      "\\begin{${1:name}}",
      "  $2",
      "\\end{${1:name}}",
      "$0"
    ]
  }
}
  1. Open a latex file with helix (hx test.tex), enter insert mode, and type b-e-g-<tab>. The cursor gets placed after the snippet. This is incorrect behavior.
  2. Open a latex file with helix (hx test.tex), enter insert mode, and type <right>-<left>-b-e-g-<tab>. There are two cursors at the location of ${1:name} in the snippet. This is correct behavior.

Helix log

Running RUST_BACKTRACE=1 hx -vv test.tex, entering insert mode, and typing b-e-g-<tab>:

~/.cache/helix/helix.log 2023-09-29T12:55:02.550 helix_view::theme [WARN] Theme: malformed ANSI: transparent 2023-09-29T12:55:02.550 helix_view::clipboard [DEBUG] Using xclip to interact with the system and selection (primary) clipboard 2023-09-29T12:55:02.683 helix_vcs [INFO] Error { context: "failed to open git repo", source: Discover( NoGitRepository { path: "/home/perlinm", }, ), } 2023-09-29T12:55:02.683 helix_vcs [INFO] failed to open diff base for /home/perlinm/test.tex 2023-09-29T12:55:02.683 helix_vcs [INFO] Error { context: "failed to open git repo", source: Discover( NoGitRepository { path: "/home/perlinm", }, ), } 2023-09-29T12:55:02.683 helix_vcs [INFO] failed to obtain current head name for /home/perlinm/test.tex 2023-09-29T12:55:02.683 helix_lsp::transport [INFO] texlab -> {"jsonrpc":"2.0","method":"initialize","params":{"capabilities":{"general":{"positionEncodings":["utf-8","utf-32","utf-16"]},"textDocument":{"codeAction":{"codeActionLiteralSupport":{"codeActionKind":{"valueSet":["","quickfix","refactor","refactor.extract","refactor.inline","refactor.rewrite","source","source.organizeImports"]}},"dataSupport":true,"disabledSupport":true,"isPreferredSupport":true,"resolveSupport":{"properties":["edit","command"]}},"completion":{"completionItem":{"deprecatedSupport":true,"insertReplaceSupport":true,"resolveSupport":{"properties":["documentation","detail","additionalTextEdits"]},"snippetSupport":true,"tagSupport":{"valueSet":[1]}},"completionItemKind":{}},"hover":{"contentFormat":["markdown"]},"inlayHint":{"dynamicRegistration":false},"publishDiagnostics":{"versionSupport":true},"rename":{"dynamicRegistration":false,"honorsChangeAnnotations":false,"prepareSupport":true},"signatureHelp":{"signatureInformation":{"activeParameterSupport":true,"documentationFormat":["markdown"],"parameterInformation":{"labelOffsetSupport":true}}}},"window":{"workDoneProgress":true},"workspace":{"applyEdit":true,"configuration":true,"didChangeConfiguration":{"dynamicRegistration":false},"didChangeWatchedFiles":{"dynamicRegistration":true,"relativePatternSupport":false},"executeCommand":{"dynamicRegistration":false},"inlayHint":{"refreshSupport":false},"symbol":{"dynamicRegistration":false},"workspaceEdit":{"documentChanges":true,"failureHandling":"abort","normalizesLineEndings":false,"resourceOperations":["create","rename","delete"]},"workspaceFolders":true}},"clientInfo":{"name":"helix","version":"23.05"},"processId":124951,"rootPath":"/home/perlinm","rootUri":null,"workspaceFolders":[]},"id":0} 2023-09-29T12:55:02.683 helix_lsp::client [INFO] Using custom LSP config: {"max_completion_items":5,"snippets_first":true} 2023-09-29T12:55:02.684 helix_view::editor [DEBUG] editor status: Loaded 1 file. 2023-09-29T12:55:02.684 helix_lsp::transport [INFO] simple-completion-language-server -> {"jsonrpc":"2.0","method":"initialize","params":{"capabilities":{"general":{"positionEncodings":["utf-8","utf-32","utf-16"]},"textDocument":{"codeAction":{"codeActionLiteralSupport":{"codeActionKind":{"valueSet":["","quickfix","refactor","refactor.extract","refactor.inline","refactor.rewrite","source","source.organizeImports"]}},"dataSupport":true,"disabledSupport":true,"isPreferredSupport":true,"resolveSupport":{"properties":["edit","command"]}},"completion":{"completionItem":{"deprecatedSupport":true,"insertReplaceSupport":true,"resolveSupport":{"properties":["documentation","detail","additionalTextEdits"]},"snippetSupport":true,"tagSupport":{"valueSet":[1]}},"completionItemKind":{}},"hover":{"contentFormat":["markdown"]},"inlayHint":{"dynamicRegistration":false},"publishDiagnostics":{"versionSupport":true},"rename":{"dynamicRegistration":false,"honorsChangeAnnotations":false,"prepareSupport":true},"signatureHelp":{"signatureInformation":{"activeParameterSupport":true,"documentationFormat":["markdown"],"parameterInformation":{"labelOffsetSupport":true}}}},"window":{"workDoneProgress":true},"workspace":{"applyEdit":true,"configuration":true,"didChangeConfiguration":{"dynamicRegistration":false},"didChangeWatchedFiles":{"dynamicRegistration":true,"relativePatternSupport":false},"executeCommand":{"dynamicRegistration":false},"inlayHint":{"refreshSupport":false},"symbol":{"dynamicRegistration":false},"workspaceEdit":{"documentChanges":true,"failureHandling":"abort","normalizesLineEndings":false,"resourceOperations":["create","rename","delete"]},"workspaceFolders":true}},"clientInfo":{"name":"helix","version":"23.05"},"initializationOptions":{"max_completion_items":5,"snippets_first":true},"processId":124951,"rootPath":"/home/perlinm","rootUri":null,"workspaceFolders":[]},"id":0} 2023-09-29T12:55:02.684 helix_tui::backend::crossterm [DEBUG] The keyboard enhancement protocol is not supported in this terminal (checked in 266.033µs) 2023-09-29T12:55:02.684 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:02.684 helix_term::application [DEBUG] received editor event: IdleTimer 2023-09-29T12:55:02.685 helix_lsp::transport [INFO] texlab <- {"jsonrpc":"2.0","id":0,"result":{"capabilities":{"completionProvider":{"resolveProvider":true,"triggerCharacters":["\\","{","}","@","/"," "]},"definitionProvider":true,"documentFormattingProvider":true,"documentHighlightProvider":true,"documentLinkProvider":{"resolveProvider":false},"documentSymbolProvider":true,"executeCommandProvider":{"commands":["texlab.cleanAuxiliary","texlab.cleanArtifacts","texlab.changeEnvironment"]},"foldingRangeProvider":true,"hoverProvider":true,"inlayHintProvider":true,"referencesProvider":true,"renameProvider":{"prepareProvider":true},"textDocumentSync":{"change":2,"openClose":true,"save":{"includeText":false}},"workspaceSymbolProvider":true},"serverInfo":{"name":"TexLab","version":"5.5.1"}}} 2023-09-29T12:55:02.685 helix_lsp::transport [INFO] texlab <- {"capabilities":{"completionProvider":{"resolveProvider":true,"triggerCharacters":["\\","{","}","@","/"," "]},"definitionProvider":true,"documentFormattingProvider":true,"documentHighlightProvider":true,"documentLinkProvider":{"resolveProvider":false},"documentSymbolProvider":true,"executeCommandProvider":{"commands":["texlab.cleanAuxiliary","texlab.cleanArtifacts","texlab.changeEnvironment"]},"foldingRangeProvider":true,"hoverProvider":true,"inlayHintProvider":true,"referencesProvider":true,"renameProvider":{"prepareProvider":true},"textDocumentSync":{"change":2,"openClose":true,"save":{"includeText":false}},"workspaceSymbolProvider":true},"serverInfo":{"name":"TexLab","version":"5.5.1"}} 2023-09-29T12:55:02.685 helix_lsp::transport [INFO] texlab -> {"jsonrpc":"2.0","method":"initialized","params":{}} 2023-09-29T12:55:02.685 helix_term::application [DEBUG] received editor event: LanguageServerMessage((0, Notification(Notification { jsonrpc: None, method: "initialized", params: None }))) 2023-09-29T12:55:02.685 helix_lsp::transport [INFO] texlab -> {"jsonrpc":"2.0","method":"textDocument/didOpen","params":{"textDocument":{"languageId":"latex","text":"\n","uri":"file:///home/perlinm/test.tex","version":0}}} 2023-09-29T12:55:02.685 helix_lsp::transport [INFO] texlab <- {"jsonrpc":"2.0","id":1,"method":"workspace/configuration","params":{"items":[{"section":"texlab"}]}} 2023-09-29T12:55:02.685 helix_term::application [DEBUG] received editor event: LanguageServerMessage((0, MethodCall(MethodCall { jsonrpc: Some(V2), method: "workspace/configuration", params: Map({"items": Array [Object {"section": String("texlab")}]}), id: Num(1) }))) 2023-09-29T12:55:02.685 helix_lsp::transport [INFO] texlab -> {"jsonrpc":"2.0","result":[null],"id":1} 2023-09-29T12:55:02.687 helix_lsp::transport [INFO] simple-completion-language-server <- {"jsonrpc":"2.0","result":{"capabilities":{"completionProvider":{},"textDocumentSync":2}},"id":0} 2023-09-29T12:55:02.687 helix_lsp::transport [INFO] simple-completion-language-server <- {"capabilities":{"completionProvider":{},"textDocumentSync":2}} 2023-09-29T12:55:02.687 helix_lsp::transport [INFO] simple-completion-language-server -> {"jsonrpc":"2.0","method":"initialized","params":{}} 2023-09-29T12:55:02.687 helix_term::application [DEBUG] received editor event: LanguageServerMessage((1, Notification(Notification { jsonrpc: None, method: "initialized", params: None }))) 2023-09-29T12:55:02.687 helix_lsp::transport [INFO] simple-completion-language-server -> {"jsonrpc":"2.0","method":"workspace/didChangeConfiguration","params":{"settings":{"max_completion_items":5,"snippets_first":true}}} 2023-09-29T12:55:02.687 helix_lsp::transport [INFO] simple-completion-language-server -> {"jsonrpc":"2.0","method":"textDocument/didOpen","params":{"textDocument":{"languageId":"latex","text":"\n","uri":"file:///home/perlinm/test.tex","version":0}}} 2023-09-29T12:55:02.687 helix_lsp::transport [INFO] simple-completion-language-server <- {"jsonrpc":"2.0","method":"window/logMessage","params":{"message":"server initialized!","type":3}} 2023-09-29T12:55:02.687 helix_lsp::transport [INFO] simple-completion-language-server <- {"jsonrpc":"2.0","method":"window/logMessage","params":{"message":"Did change configuration: DidChangeConfigurationParams { settings: Object {\"max_completion_items\": Number(5), \"snippets_first\": Bool(true)} }","type":3}} 2023-09-29T12:55:02.687 helix_term::application [DEBUG] received editor event: LanguageServerMessage((1, Notification(Notification { jsonrpc: Some(V2), method: "window/logMessage", params: Map({"message": String("server initialized!"), "type": Number(3)}) }))) 2023-09-29T12:55:02.687 helix_term::application [INFO] window/logMessage: LogMessageParams { typ: Info, message: "server initialized!" } 2023-09-29T12:55:02.687 helix_lsp::transport [INFO] simple-completion-language-server <- {"jsonrpc":"2.0","method":"window/logMessage","params":{"message":"Did open: file:///home/perlinm/test.tex","type":3}} 2023-09-29T12:55:02.687 helix_term::application [DEBUG] received editor event: LanguageServerMessage((1, Notification(Notification { jsonrpc: Some(V2), method: "window/logMessage", params: Map({"message": String("Did change configuration: DidChangeConfigurationParams { settings: Object {\"max_completion_items\": Number(5), \"snippets_first\": Bool(true)} }"), "type": Number(3)}) }))) 2023-09-29T12:55:02.687 helix_term::application [INFO] window/logMessage: LogMessageParams { typ: Info, message: "Did change configuration: DidChangeConfigurationParams { settings: Object {\"max_completion_items\": Number(5), \"snippets_first\": Bool(true)} }" } 2023-09-29T12:55:02.687 helix_term::application [DEBUG] received editor event: LanguageServerMessage((1, Notification(Notification { jsonrpc: Some(V2), method: "window/logMessage", params: Map({"message": String("Did open: file:///home/perlinm/test.tex"), "type": Number(3)}) }))) 2023-09-29T12:55:02.687 helix_term::application [INFO] window/logMessage: LogMessageParams { typ: Info, message: "Did open: file:///home/perlinm/test.tex" } 2023-09-29T12:55:02.720 helix_term::application [DEBUG] received editor event: Redraw 2023-09-29T12:55:02.720 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:02.985 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:02.986 helix_lsp::transport [INFO] texlab <- {"jsonrpc":"2.0","method":"textDocument/publishDiagnostics","params":{"diagnostics":[],"uri":"file:///home/perlinm/test.tex"}} 2023-09-29T12:55:02.986 helix_term::application [DEBUG] received editor event: LanguageServerMessage((0, Notification(Notification { jsonrpc: Some(V2), method: "textDocument/publishDiagnostics", params: Map({"diagnostics": Array [], "uri": String("file:///home/perlinm/test.tex")}) }))) 2023-09-29T12:55:03.020 helix_term::application [DEBUG] received editor event: Redraw 2023-09-29T12:55:03.021 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:03.204 helix_lsp::transport [INFO] texlab -> {"jsonrpc":"2.0","method":"textDocument/didChange","params":{"contentChanges":[{"range":{"end":{"character":0,"line":0},"start":{"character":0,"line":0}},"text":"b"}],"textDocument":{"uri":"file:///home/perlinm/test.tex","version":1}}} 2023-09-29T12:55:03.205 helix_lsp::transport [INFO] simple-completion-language-server -> {"jsonrpc":"2.0","method":"textDocument/didChange","params":{"contentChanges":[{"range":{"end":{"character":0,"line":0},"start":{"character":0,"line":0}},"text":"b"}],"textDocument":{"uri":"file:///home/perlinm/test.tex","version":1}}} 2023-09-29T12:55:03.205 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:03.206 helix_term::application [DEBUG] received editor event: IdleTimer 2023-09-29T12:55:03.206 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:03.206 helix_lsp::transport [INFO] texlab -> {"jsonrpc":"2.0","method":"textDocument/completion","params":{"position":{"character":1,"line":0},"textDocument":{"uri":"file:///home/perlinm/test.tex"}},"id":1} 2023-09-29T12:55:03.206 helix_lsp::transport [INFO] simple-completion-language-server -> {"jsonrpc":"2.0","method":"textDocument/completion","params":{"position":{"character":1,"line":0},"textDocument":{"uri":"file:///home/perlinm/test.tex"}},"id":1} 2023-09-29T12:55:03.207 helix_lsp::transport [INFO] texlab <- {"jsonrpc":"2.0","id":1,"result":{"isIncomplete":false,"items":[]}} 2023-09-29T12:55:03.207 helix_lsp::transport [INFO] texlab <- {"isIncomplete":false,"items":[]} 2023-09-29T12:55:03.207 helix_lsp::transport [INFO] simple-completion-language-server <- {"jsonrpc":"2.0","result":[{"detail":"\\begin{${1:name}}\n $2\n\\end{${1:name}}\n$0","insertText":"\\begin{${1:name}}\n $2\n\\end{${1:name}}\n$0","insertTextFormat":2,"kind":15,"label":"begin"}],"id":1} 2023-09-29T12:55:03.207 helix_lsp::transport [INFO] simple-completion-language-server <- [{"detail":"\\begin{${1:name}}\n $2\n\\end{${1:name}}\n$0","insertText":"\\begin{${1:name}}\n $2\n\\end{${1:name}}\n$0","insertTextFormat":2,"kind":15,"label":"begin"}] 2023-09-29T12:55:03.207 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:03.275 helix_lsp::transport [INFO] texlab -> {"jsonrpc":"2.0","method":"textDocument/didChange","params":{"contentChanges":[{"range":{"end":{"character":1,"line":0},"start":{"character":1,"line":0}},"text":"e"}],"textDocument":{"uri":"file:///home/perlinm/test.tex","version":2}}} 2023-09-29T12:55:03.275 helix_lsp::transport [INFO] simple-completion-language-server -> {"jsonrpc":"2.0","method":"textDocument/didChange","params":{"contentChanges":[{"range":{"end":{"character":1,"line":0},"start":{"character":1,"line":0}},"text":"e"}],"textDocument":{"uri":"file:///home/perlinm/test.tex","version":2}}} 2023-09-29T12:55:03.275 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:03.275 helix_term::application [DEBUG] received editor event: IdleTimer 2023-09-29T12:55:03.397 helix_lsp::transport [INFO] texlab -> {"jsonrpc":"2.0","method":"textDocument/didChange","params":{"contentChanges":[{"range":{"end":{"character":2,"line":0},"start":{"character":2,"line":0}},"text":"g"}],"textDocument":{"uri":"file:///home/perlinm/test.tex","version":3}}} 2023-09-29T12:55:03.397 helix_lsp::transport [INFO] simple-completion-language-server -> {"jsonrpc":"2.0","method":"textDocument/didChange","params":{"contentChanges":[{"range":{"end":{"character":2,"line":0},"start":{"character":2,"line":0}},"text":"g"}],"textDocument":{"uri":"file:///home/perlinm/test.tex","version":3}}} 2023-09-29T12:55:03.398 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:03.399 helix_term::application [DEBUG] received editor event: IdleTimer 2023-09-29T12:55:03.506 helix_lsp::transport [INFO] texlab <- {"jsonrpc":"2.0","method":"textDocument/publishDiagnostics","params":{"diagnostics":[],"uri":"file:///home/perlinm/test.tex"}} 2023-09-29T12:55:03.506 helix_term::application [DEBUG] received editor event: LanguageServerMessage((0, Notification(Notification { jsonrpc: Some(V2), method: "textDocument/publishDiagnostics", params: Map({"diagnostics": Array [], "uri": String("file:///home/perlinm/test.tex")}) }))) 2023-09-29T12:55:03.540 helix_term::application [DEBUG] received editor event: Redraw 2023-09-29T12:55:03.540 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:03.576 helix_lsp::transport [INFO] texlab <- {"jsonrpc":"2.0","method":"textDocument/publishDiagnostics","params":{"diagnostics":[],"uri":"file:///home/perlinm/test.tex"}} 2023-09-29T12:55:03.576 helix_term::application [DEBUG] received editor event: LanguageServerMessage((0, Notification(Notification { jsonrpc: Some(V2), method: "textDocument/publishDiagnostics", params: Map({"diagnostics": Array [], "uri": String("file:///home/perlinm/test.tex")}) }))) 2023-09-29T12:55:03.610 helix_term::application [DEBUG] received editor event: Redraw 2023-09-29T12:55:03.611 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:03.662 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:03.663 helix_term::application [DEBUG] received editor event: IdleTimer 2023-09-29T12:55:03.698 helix_lsp::transport [INFO] texlab <- {"jsonrpc":"2.0","method":"textDocument/publishDiagnostics","params":{"diagnostics":[],"uri":"file:///home/perlinm/test.tex"}} 2023-09-29T12:55:03.699 helix_term::application [DEBUG] received editor event: LanguageServerMessage((0, Notification(Notification { jsonrpc: Some(V2), method: "textDocument/publishDiagnostics", params: Map({"diagnostics": Array [], "uri": String("file:///home/perlinm/test.tex")}) }))) 2023-09-29T12:55:03.733 helix_term::application [DEBUG] received editor event: Redraw 2023-09-29T12:55:03.733 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:04.429 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:06.344 helix_view::theme [WARN] Theme: malformed ANSI: transparent

Running RUST_BACKTRACE=1 hx -vv test.tex, entering insert mode, and typing <right>-<left>-b-e-g-<tab>:

~/.cache/helix/helix.log 2023-09-29T12:55:51.701 helix_view::theme [WARN] Theme: malformed ANSI: transparent 2023-09-29T12:55:51.701 helix_view::clipboard [DEBUG] Using xclip to interact with the system and selection (primary) clipboard 2023-09-29T12:55:51.834 helix_vcs [INFO] Error { context: "failed to open git repo", source: Discover( NoGitRepository { path: "/home/perlinm", }, ), } 2023-09-29T12:55:51.834 helix_vcs [INFO] failed to open diff base for /home/perlinm/test.tex 2023-09-29T12:55:51.834 helix_vcs [INFO] Error { context: "failed to open git repo", source: Discover( NoGitRepository { path: "/home/perlinm", }, ), } 2023-09-29T12:55:51.834 helix_vcs [INFO] failed to obtain current head name for /home/perlinm/test.tex 2023-09-29T12:55:51.835 helix_lsp::transport [INFO] texlab -> {"jsonrpc":"2.0","method":"initialize","params":{"capabilities":{"general":{"positionEncodings":["utf-8","utf-32","utf-16"]},"textDocument":{"codeAction":{"codeActionLiteralSupport":{"codeActionKind":{"valueSet":["","quickfix","refactor","refactor.extract","refactor.inline","refactor.rewrite","source","source.organizeImports"]}},"dataSupport":true,"disabledSupport":true,"isPreferredSupport":true,"resolveSupport":{"properties":["edit","command"]}},"completion":{"completionItem":{"deprecatedSupport":true,"insertReplaceSupport":true,"resolveSupport":{"properties":["documentation","detail","additionalTextEdits"]},"snippetSupport":true,"tagSupport":{"valueSet":[1]}},"completionItemKind":{}},"hover":{"contentFormat":["markdown"]},"inlayHint":{"dynamicRegistration":false},"publishDiagnostics":{"versionSupport":true},"rename":{"dynamicRegistration":false,"honorsChangeAnnotations":false,"prepareSupport":true},"signatureHelp":{"signatureInformation":{"activeParameterSupport":true,"documentationFormat":["markdown"],"parameterInformation":{"labelOffsetSupport":true}}}},"window":{"workDoneProgress":true},"workspace":{"applyEdit":true,"configuration":true,"didChangeConfiguration":{"dynamicRegistration":false},"didChangeWatchedFiles":{"dynamicRegistration":true,"relativePatternSupport":false},"executeCommand":{"dynamicRegistration":false},"inlayHint":{"refreshSupport":false},"symbol":{"dynamicRegistration":false},"workspaceEdit":{"documentChanges":true,"failureHandling":"abort","normalizesLineEndings":false,"resourceOperations":["create","rename","delete"]},"workspaceFolders":true}},"clientInfo":{"name":"helix","version":"23.05"},"processId":125191,"rootPath":"/home/perlinm","rootUri":null,"workspaceFolders":[]},"id":0} 2023-09-29T12:55:51.835 helix_lsp::client [INFO] Using custom LSP config: {"max_completion_items":5,"snippets_first":true} 2023-09-29T12:55:51.835 helix_view::editor [DEBUG] editor status: Loaded 1 file. 2023-09-29T12:55:51.835 helix_lsp::transport [INFO] simple-completion-language-server -> {"jsonrpc":"2.0","method":"initialize","params":{"capabilities":{"general":{"positionEncodings":["utf-8","utf-32","utf-16"]},"textDocument":{"codeAction":{"codeActionLiteralSupport":{"codeActionKind":{"valueSet":["","quickfix","refactor","refactor.extract","refactor.inline","refactor.rewrite","source","source.organizeImports"]}},"dataSupport":true,"disabledSupport":true,"isPreferredSupport":true,"resolveSupport":{"properties":["edit","command"]}},"completion":{"completionItem":{"deprecatedSupport":true,"insertReplaceSupport":true,"resolveSupport":{"properties":["documentation","detail","additionalTextEdits"]},"snippetSupport":true,"tagSupport":{"valueSet":[1]}},"completionItemKind":{}},"hover":{"contentFormat":["markdown"]},"inlayHint":{"dynamicRegistration":false},"publishDiagnostics":{"versionSupport":true},"rename":{"dynamicRegistration":false,"honorsChangeAnnotations":false,"prepareSupport":true},"signatureHelp":{"signatureInformation":{"activeParameterSupport":true,"documentationFormat":["markdown"],"parameterInformation":{"labelOffsetSupport":true}}}},"window":{"workDoneProgress":true},"workspace":{"applyEdit":true,"configuration":true,"didChangeConfiguration":{"dynamicRegistration":false},"didChangeWatchedFiles":{"dynamicRegistration":true,"relativePatternSupport":false},"executeCommand":{"dynamicRegistration":false},"inlayHint":{"refreshSupport":false},"symbol":{"dynamicRegistration":false},"workspaceEdit":{"documentChanges":true,"failureHandling":"abort","normalizesLineEndings":false,"resourceOperations":["create","rename","delete"]},"workspaceFolders":true}},"clientInfo":{"name":"helix","version":"23.05"},"initializationOptions":{"max_completion_items":5,"snippets_first":true},"processId":125191,"rootPath":"/home/perlinm","rootUri":null,"workspaceFolders":[]},"id":0} 2023-09-29T12:55:51.835 helix_tui::backend::crossterm [DEBUG] The keyboard enhancement protocol is not supported in this terminal (checked in 352.321µs) 2023-09-29T12:55:51.836 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:51.836 helix_term::application [DEBUG] received editor event: IdleTimer 2023-09-29T12:55:51.836 helix_lsp::transport [INFO] texlab <- {"jsonrpc":"2.0","id":0,"result":{"capabilities":{"completionProvider":{"resolveProvider":true,"triggerCharacters":["\\","{","}","@","/"," "]},"definitionProvider":true,"documentFormattingProvider":true,"documentHighlightProvider":true,"documentLinkProvider":{"resolveProvider":false},"documentSymbolProvider":true,"executeCommandProvider":{"commands":["texlab.cleanAuxiliary","texlab.cleanArtifacts","texlab.changeEnvironment"]},"foldingRangeProvider":true,"hoverProvider":true,"inlayHintProvider":true,"referencesProvider":true,"renameProvider":{"prepareProvider":true},"textDocumentSync":{"change":2,"openClose":true,"save":{"includeText":false}},"workspaceSymbolProvider":true},"serverInfo":{"name":"TexLab","version":"5.5.1"}}} 2023-09-29T12:55:51.836 helix_lsp::transport [INFO] texlab <- {"capabilities":{"completionProvider":{"resolveProvider":true,"triggerCharacters":["\\","{","}","@","/"," "]},"definitionProvider":true,"documentFormattingProvider":true,"documentHighlightProvider":true,"documentLinkProvider":{"resolveProvider":false},"documentSymbolProvider":true,"executeCommandProvider":{"commands":["texlab.cleanAuxiliary","texlab.cleanArtifacts","texlab.changeEnvironment"]},"foldingRangeProvider":true,"hoverProvider":true,"inlayHintProvider":true,"referencesProvider":true,"renameProvider":{"prepareProvider":true},"textDocumentSync":{"change":2,"openClose":true,"save":{"includeText":false}},"workspaceSymbolProvider":true},"serverInfo":{"name":"TexLab","version":"5.5.1"}} 2023-09-29T12:55:51.836 helix_lsp::transport [INFO] texlab -> {"jsonrpc":"2.0","method":"initialized","params":{}} 2023-09-29T12:55:51.836 helix_lsp::transport [INFO] texlab <- {"jsonrpc":"2.0","id":1,"method":"workspace/configuration","params":{"items":[{"section":"texlab"}]}} 2023-09-29T12:55:51.836 helix_term::application [DEBUG] received editor event: LanguageServerMessage((0, Notification(Notification { jsonrpc: None, method: "initialized", params: None }))) 2023-09-29T12:55:51.836 helix_term::application [DEBUG] received editor event: LanguageServerMessage((0, MethodCall(MethodCall { jsonrpc: Some(V2), method: "workspace/configuration", params: Map({"items": Array [Object {"section": String("texlab")}]}), id: Num(1) }))) 2023-09-29T12:55:51.836 helix_lsp::transport [INFO] texlab -> {"jsonrpc":"2.0","method":"textDocument/didOpen","params":{"textDocument":{"languageId":"latex","text":"\n","uri":"file:///home/perlinm/test.tex","version":0}}} 2023-09-29T12:55:51.836 helix_lsp::transport [INFO] texlab -> {"jsonrpc":"2.0","result":[null],"id":1} 2023-09-29T12:55:51.838 helix_lsp::transport [INFO] simple-completion-language-server <- {"jsonrpc":"2.0","result":{"capabilities":{"completionProvider":{},"textDocumentSync":2}},"id":0} 2023-09-29T12:55:51.838 helix_lsp::transport [INFO] simple-completion-language-server <- {"capabilities":{"completionProvider":{},"textDocumentSync":2}} 2023-09-29T12:55:51.838 helix_lsp::transport [INFO] simple-completion-language-server -> {"jsonrpc":"2.0","method":"initialized","params":{}} 2023-09-29T12:55:51.838 helix_term::application [DEBUG] received editor event: LanguageServerMessage((1, Notification(Notification { jsonrpc: None, method: "initialized", params: None }))) 2023-09-29T12:55:51.839 helix_lsp::transport [INFO] simple-completion-language-server <- {"jsonrpc":"2.0","method":"window/logMessage","params":{"message":"server initialized!","type":3}} 2023-09-29T12:55:51.839 helix_lsp::transport [INFO] simple-completion-language-server -> {"jsonrpc":"2.0","method":"workspace/didChangeConfiguration","params":{"settings":{"max_completion_items":5,"snippets_first":true}}} 2023-09-29T12:55:51.839 helix_term::application [DEBUG] received editor event: LanguageServerMessage((1, Notification(Notification { jsonrpc: Some(V2), method: "window/logMessage", params: Map({"message": String("server initialized!"), "type": Number(3)}) }))) 2023-09-29T12:55:51.839 helix_lsp::transport [INFO] simple-completion-language-server -> {"jsonrpc":"2.0","method":"textDocument/didOpen","params":{"textDocument":{"languageId":"latex","text":"\n","uri":"file:///home/perlinm/test.tex","version":0}}} 2023-09-29T12:55:51.839 helix_term::application [INFO] window/logMessage: LogMessageParams { typ: Info, message: "server initialized!" } 2023-09-29T12:55:51.839 helix_lsp::transport [INFO] simple-completion-language-server <- {"jsonrpc":"2.0","method":"window/logMessage","params":{"message":"Did change configuration: DidChangeConfigurationParams { settings: Object {\"max_completion_items\": Number(5), \"snippets_first\": Bool(true)} }","type":3}} 2023-09-29T12:55:51.839 helix_lsp::transport [INFO] simple-completion-language-server <- {"jsonrpc":"2.0","method":"window/logMessage","params":{"message":"Did open: file:///home/perlinm/test.tex","type":3}} 2023-09-29T12:55:51.839 helix_term::application [DEBUG] received editor event: LanguageServerMessage((1, Notification(Notification { jsonrpc: Some(V2), method: "window/logMessage", params: Map({"message": String("Did change configuration: DidChangeConfigurationParams { settings: Object {\"max_completion_items\": Number(5), \"snippets_first\": Bool(true)} }"), "type": Number(3)}) }))) 2023-09-29T12:55:51.839 helix_term::application [INFO] window/logMessage: LogMessageParams { typ: Info, message: "Did change configuration: DidChangeConfigurationParams { settings: Object {\"max_completion_items\": Number(5), \"snippets_first\": Bool(true)} }" } 2023-09-29T12:55:51.839 helix_term::application [DEBUG] received editor event: LanguageServerMessage((1, Notification(Notification { jsonrpc: Some(V2), method: "window/logMessage", params: Map({"message": String("Did open: file:///home/perlinm/test.tex"), "type": Number(3)}) }))) 2023-09-29T12:55:51.839 helix_term::application [INFO] window/logMessage: LogMessageParams { typ: Info, message: "Did open: file:///home/perlinm/test.tex" } 2023-09-29T12:55:51.871 helix_term::application [DEBUG] received editor event: Redraw 2023-09-29T12:55:51.871 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:52.137 helix_lsp::transport [INFO] texlab <- {"jsonrpc":"2.0","method":"textDocument/publishDiagnostics","params":{"diagnostics":[],"uri":"file:///home/perlinm/test.tex"}} 2023-09-29T12:55:52.137 helix_term::application [DEBUG] received editor event: LanguageServerMessage((0, Notification(Notification { jsonrpc: Some(V2), method: "textDocument/publishDiagnostics", params: Map({"diagnostics": Array [], "uri": String("file:///home/perlinm/test.tex")}) }))) 2023-09-29T12:55:52.171 helix_term::application [DEBUG] received editor event: Redraw 2023-09-29T12:55:52.172 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:52.349 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:52.743 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:52.744 helix_term::application [DEBUG] received editor event: IdleTimer 2023-09-29T12:55:52.744 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:53.184 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:53.185 helix_term::application [DEBUG] received editor event: IdleTimer 2023-09-29T12:55:53.185 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:53.622 helix_lsp::transport [INFO] texlab -> {"jsonrpc":"2.0","method":"textDocument/didChange","params":{"contentChanges":[{"range":{"end":{"character":0,"line":0},"start":{"character":0,"line":0}},"text":"b"}],"textDocument":{"uri":"file:///home/perlinm/test.tex","version":1}}} 2023-09-29T12:55:53.623 helix_lsp::transport [INFO] simple-completion-language-server -> {"jsonrpc":"2.0","method":"textDocument/didChange","params":{"contentChanges":[{"range":{"end":{"character":0,"line":0},"start":{"character":0,"line":0}},"text":"b"}],"textDocument":{"uri":"file:///home/perlinm/test.tex","version":1}}} 2023-09-29T12:55:53.623 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:53.624 helix_term::application [DEBUG] received editor event: IdleTimer 2023-09-29T12:55:53.624 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:53.624 helix_lsp::transport [INFO] texlab -> {"jsonrpc":"2.0","method":"textDocument/completion","params":{"position":{"character":1,"line":0},"textDocument":{"uri":"file:///home/perlinm/test.tex"}},"id":1} 2023-09-29T12:55:53.624 helix_lsp::transport [INFO] simple-completion-language-server -> {"jsonrpc":"2.0","method":"textDocument/completion","params":{"position":{"character":1,"line":0},"textDocument":{"uri":"file:///home/perlinm/test.tex"}},"id":1} 2023-09-29T12:55:53.625 helix_lsp::transport [INFO] texlab <- {"jsonrpc":"2.0","id":1,"result":{"isIncomplete":false,"items":[]}} 2023-09-29T12:55:53.625 helix_lsp::transport [INFO] texlab <- {"isIncomplete":false,"items":[]} 2023-09-29T12:55:53.625 helix_lsp::transport [INFO] simple-completion-language-server <- {"jsonrpc":"2.0","result":[{"detail":"\\begin{${1:name}}\n $2\n\\end{${1:name}}\n$0","insertText":"\\begin{${1:name}}\n $2\n\\end{${1:name}}\n$0","insertTextFormat":2,"kind":15,"label":"begin"}],"id":1} 2023-09-29T12:55:53.625 helix_lsp::transport [INFO] simple-completion-language-server <- [{"detail":"\\begin{${1:name}}\n $2\n\\end{${1:name}}\n$0","insertText":"\\begin{${1:name}}\n $2\n\\end{${1:name}}\n$0","insertTextFormat":2,"kind":15,"label":"begin"}] 2023-09-29T12:55:53.625 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:53.716 helix_lsp::transport [INFO] texlab -> {"jsonrpc":"2.0","method":"textDocument/didChange","params":{"contentChanges":[{"range":{"end":{"character":1,"line":0},"start":{"character":1,"line":0}},"text":"e"}],"textDocument":{"uri":"file:///home/perlinm/test.tex","version":2}}} 2023-09-29T12:55:53.716 helix_lsp::transport [INFO] simple-completion-language-server -> {"jsonrpc":"2.0","method":"textDocument/didChange","params":{"contentChanges":[{"range":{"end":{"character":1,"line":0},"start":{"character":1,"line":0}},"text":"e"}],"textDocument":{"uri":"file:///home/perlinm/test.tex","version":2}}} 2023-09-29T12:55:53.716 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:53.717 helix_term::application [DEBUG] received editor event: IdleTimer 2023-09-29T12:55:53.858 helix_lsp::transport [INFO] texlab -> {"jsonrpc":"2.0","method":"textDocument/didChange","params":{"contentChanges":[{"range":{"end":{"character":2,"line":0},"start":{"character":2,"line":0}},"text":"g"}],"textDocument":{"uri":"file:///home/perlinm/test.tex","version":3}}} 2023-09-29T12:55:53.858 helix_lsp::transport [INFO] simple-completion-language-server -> {"jsonrpc":"2.0","method":"textDocument/didChange","params":{"contentChanges":[{"range":{"end":{"character":2,"line":0},"start":{"character":2,"line":0}},"text":"g"}],"textDocument":{"uri":"file:///home/perlinm/test.tex","version":3}}} 2023-09-29T12:55:53.858 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:53.859 helix_term::application [DEBUG] received editor event: IdleTimer 2023-09-29T12:55:53.924 helix_lsp::transport [INFO] texlab <- {"jsonrpc":"2.0","method":"textDocument/publishDiagnostics","params":{"diagnostics":[],"uri":"file:///home/perlinm/test.tex"}} 2023-09-29T12:55:53.924 helix_term::application [DEBUG] received editor event: LanguageServerMessage((0, Notification(Notification { jsonrpc: Some(V2), method: "textDocument/publishDiagnostics", params: Map({"diagnostics": Array [], "uri": String("file:///home/perlinm/test.tex")}) }))) 2023-09-29T12:55:53.959 helix_term::application [DEBUG] received editor event: Redraw 2023-09-29T12:55:53.959 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:54.017 helix_lsp::transport [INFO] texlab <- {"jsonrpc":"2.0","method":"textDocument/publishDiagnostics","params":{"diagnostics":[],"uri":"file:///home/perlinm/test.tex"}} 2023-09-29T12:55:54.018 helix_term::application [DEBUG] received editor event: LanguageServerMessage((0, Notification(Notification { jsonrpc: Some(V2), method: "textDocument/publishDiagnostics", params: Map({"diagnostics": Array [], "uri": String("file:///home/perlinm/test.tex")}) }))) 2023-09-29T12:55:54.052 helix_term::application [DEBUG] received editor event: Redraw 2023-09-29T12:55:54.052 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:54.069 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:54.071 helix_term::application [DEBUG] received editor event: IdleTimer 2023-09-29T12:55:54.159 helix_lsp::transport [INFO] texlab <- {"jsonrpc":"2.0","method":"textDocument/publishDiagnostics","params":{"diagnostics":[],"uri":"file:///home/perlinm/test.tex"}} 2023-09-29T12:55:54.160 helix_term::application [DEBUG] received editor event: LanguageServerMessage((0, Notification(Notification { jsonrpc: Some(V2), method: "textDocument/publishDiagnostics", params: Map({"diagnostics": Array [], "uri": String("file:///home/perlinm/test.tex")}) }))) 2023-09-29T12:55:54.194 helix_term::application [DEBUG] received editor event: Redraw 2023-09-29T12:55:54.195 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:55.140 helix_view::document [DEBUG] id 1 modified - last saved: 0, current: 0 2023-09-29T12:55:56.526 helix_view::theme [WARN] Theme: malformed ANSI: transparent

Platform

Linux (nixos-23.05)

Terminal Emulator

alacritty 0.12.0

Helix Version

helix 23.05

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Category: This is a bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant