Skip to content

Defer language server startup until first insert#519

Open
owenthewizard wants to merge 1 commit intoExafunction:mainfrom
owenthewizard:main
Open

Defer language server startup until first insert#519
owenthewizard wants to merge 1 commit intoExafunction:mainfrom
owenthewizard:main

Conversation

@owenthewizard
Copy link
Copy Markdown

The language server was being started on BufEnter at startup, which caused its stdout/stderr output to be misinterpreted by the terminal as keyboard input. This resulted in garbage appearing in Vim's input buffer that needed to be manually cleared.

By deferring the server startup to InsertEnter (when the user first enters insert mode), we avoid this issue while still ensuring the server is available when needed for completions.

The guard condition checks codeium_server_started to prevent multiple startup attempts.

The language server was being started on BufEnter at startup, which
caused its stdout/stderr output to be misinterpreted by the terminal
as keyboard input. This resulted in garbage appearing in Vim's input
buffer that needed to be manually cleared.

By deferring the server startup to InsertEnter (when the user first
enters insert mode), we avoid this issue while still ensuring the
server is available when needed for completions.

The guard condition checks codeium_server_started to prevent multiple
startup attempts.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant