Skip to content

CLI Runtime: Improve handling of language server failures #5308

@StachuDotNet

Description

@StachuDotNet

Our language server is run by our darklang CLI runtime/executable, in a long-running function that's constantly consuming stdin and putting responses on stdout.

Generally this works great -- we get JSON blobs in, and put JSON blobs out.

However, we aren't currently handling failures very gracefully -- if there's a runtime exception, we end up printing that, which isn't json and thus causes the language server (and the extension which houses it) to fail/crash.

I imagine we'll support a darklang lsp command which will have special functionality for handling such failures gracefully.

Metadata

Metadata

Assignees

Labels

internal-onlyThis involves CI, our infra, or otherwise should be done by an internal dev

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions