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

onivim test run #40

Closed
razcore-rad opened this issue Nov 2, 2018 · 4 comments
Closed

onivim test run #40

razcore-rad opened this issue Nov 2, 2018 · 4 comments

Comments

@razcore-rad
Copy link

razcore-rad commented Nov 2, 2018

Hello there!

I tried installing the language server (in ubuntu 18.10: npm i -g purescript-language-server) and using it in onivim with no success. Onivim comes with language server support and it does seem that there's some purescript-language-server activity (in the developer console), but it doesn't do anything more than that, as it can be seen in the screenshot. I have no idea if this is oni's fault or not, I was hoping you could give me some pointers on how I could debug this, perhaps you could think of something :)

image

The language server is configured in oni with:

"language.purescript.languageServer.command": "purescript-language-server",
"language.purescript.languageServer.arguments": ["--stdio"],

oni support only --stdio. Can't think of anything else right now. Thanks!

@nwolverson
Copy link
Owner

The language server should send some startup logs via window/logMessage which would help in diagnosing things once you get a bit further...

Check this issue #38 - per that issue maybe try starting with args --stdio --config {} - for some reason the initial integration with vscode meant the server waits to recieve a config message (unless you pass it config on command line), I think this can/should be reworked now

@razcore-rad
Copy link
Author

For some reason I missed your answer. I'll try it out and see if it gets me anywhere. Thanks a bunch

@razcore-rad
Copy link
Author

razcore-rad commented Nov 10, 2018

So, as far as I can tell there's no way to print/see window/logMessage responses in onivim. I think the --config {} thing might have moved stuff further a tiny bit although it still doesn't work.

I've enabled oni debugging and this is some stuff I'm getting in the developer console, but I don't know how to proceed any further.

I've removed extra debug output that isn't related to the completion server - I hope :)

[COMPLETION] Requesting completions at line 22 and character 12
bundle.js:1 [LANGUAGE] Sending request: textDocument/completion|{"textDocument":{"uri":"file:///home/razvan/Documents/learn/purescript/src/ByExample.purs"},"position":{"line":22,"character":12}}
bundle.js:1 [SnippetCompletionProvider::getCompletions] Starting...
bundle.js:1 [Language Client] Request textDocument/completion - /home/razvan/Documents/learn/purescript/src/ByExample.purs: start
bundle.js:1 Error: Request textDocument/completion failed with message: connect ECONNREFUSED 127.0.0.1:15502
    at new ResponseError (/opt/Oni/resources/app/node_modules/vscode-jsonrpc/lib/messages.js:46)
    at handleResponse (/opt/Oni/resources/app/node_modules/vscode-jsonrpc/lib/main.js:430)
    at processMessageQueue (/opt/Oni/resources/app/node_modules/vscode-jsonrpc/lib/main.js:258)
    at Immediate._onImmediate (/opt/Oni/resources/app/node_modules/vscode-jsonrpc/lib/main.js:242)
    at runCallback (timers.js:789)
    at tryOnImmediate (timers.js:751)
    at processImmediate [as _immediateCallback] (timers.js:722)
bundle.js:1 [REDUX - COMPLETION_STORE][ACTION] GET_COMPLETIONS_RESULT
bundle.js:1 [REDUX - COMPLETION_STORE][ACTION] null

The error message is definitely tied to purescript language server somehow, but I have no idea how and the the completion results... seem null or something.

And some more errors

Error: Request textDocument/definition failed with message: connect ECONNREFUSED 127.0.0.1:15502
    at new ResponseError (/opt/Oni/resources/app/node_modules/vscode-jsonrpc/lib/messages.js:46)
    at handleResponse (/opt/Oni/resources/app/node_modules/vscode-jsonrpc/lib/main.js:430)
    at processMessageQueue (/opt/Oni/resources/app/node_modules/vscode-jsonrpc/lib/main.js:258)
    at Immediate._onImmediate (/opt/Oni/resources/app/node_modules/vscode-jsonrpc/lib/main.js:242)
    at runCallback (timers.js:789)
    at tryOnImmediate (timers.js:751)
    at processImmediate [as _immediateCallback] (timers.js:722)

I suppose it depends on what triggers the thing so perhaps there's more errors out there to be discovered.

@nwolverson
Copy link
Owner

Closing due to lack of activity & linked repo is archived - presumably onivim 2 may not share the same issues

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants