-
Notifications
You must be signed in to change notification settings - Fork 39
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
(GH-#187) Add a stdio mode to the language server #188
Conversation
Thanks for the PR @Ace13 . I'll review it soon. |
@Ace13 Are you ok with me adding on some commits to this PR? |
Couple of things I see
|
I didn't touch any of that client detection, since there's technically a client through the entirety of the servers lifetime. Not sure if that's the right way to go about it though, or if actually tracking a client is more appropriate. I also did add a small mode for specifying And I don't particularly mind if you want to add some commits as well. |
Yeah...just trying to think, if the language server is started as a child process, and the parent dies, then the child is orphaned. Will the language server be able to detect that ... I'll see if I can set that up as testing scenario. |
Nope...forgot that the parent process is sometimes cmd.exe |
On second thoughts. I think I'm being too defensive. Will just write some tests and then merge it. |
Hrmm...so the TCP server code seems to be broken. Good news is, my tests were failing because of it! I'll keep working on it. Thanks @Ace13 |
Previously the case compare was looking for a non zero result which meant even if a debug file was specified, it still used STDOUT. This commit now correctly identifies when a user enters stdout as the debug destination.
…ervers This commit adds smoke integration tests for both the TCP and STDIO variants of the Puppet Language Server.
Previously older ruby versions with older Puppet gems would emit a warning about Fiddler and DL on STDOUT. This would confuse a STDIO Client as it pollutes STDOUT with non JSON compliant text. This commit suppresses verbose error messages during the gem require statements.
0953813
to
2de87ea
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When merged this will create a GH issue to add this to the docs and to refactor the TCP Socket classes to be more generic.
@Ace13 You ok with my additional commits? |
No issues with them, looks fine to me. |
I'm unsure on how to add a test for this feature, but if someone has a good suggestion for that then I'll happily write one.