I wanner use the stdin ,stdout and tcp at the sametime #342
-
Use stdin and stdout, the editor will work with the lsp , and Sometime I cannot view the log easily, I wanner use tcp socket to view the logs ,so if it is posible with tower-lsp? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Which logs are you referring to? Do you mean a trace of the LSP messages between the client and server? If you have created a vscode extension for the language server, you can view the LSP message trace in the vscode editor by enabling a specific trace setting. Otherwise, I believe you could possibly do this with tower middleware but I don't have any particular pointers for where to start with that. You might try asking on the tokio discord in the tower channel. In theory you should also be able to do this by implementing custom types In that case, you would have some custom type |
Beta Was this translation helpful? Give feedback.
Which logs are you referring to? Do you mean a trace of the LSP messages between the client and server?
If you have created a vscode extension for the language server, you can view the LSP message trace in the vscode editor by enabling a specific trace setting.
Otherwise, I believe you could possibly do this with tower middleware but I don't have any particular pointers for where to start with that. You might try asking on the tokio discord in the tower channel.
In theory you should also be able to do this by implementing custom types
I: AsyncRead
andO: AsyncWrite
for the Server impl which you pass toServer::new
.In that case, you would have some custom type
I: AsyncRead
that behaves li…