vknabel / vscode-swift-development-environment

New home of Swift Development Environment for VS Code
https://marketplace.visualstudio.com/items?itemName=vknabel.vscode-swift-development-environment
Apache License 2.0
175 stars 14 forks source link

No autocomplete on Swift 4.1 #13

Closed thomas-alrek closed 6 years ago

thomas-alrek commented 6 years ago

I just installed this extension and compiled Sourcekite. I get correct syntax highlighting, but the autocompletion/IntelliSense seems to be broken.

If i type a function name, I do not get autocompletion for the various function arguments.

This is on Swift 4.1 (swiftlang-902.0.48 clang-902.0.39.1). I do not get any errors in the debug console.

vknabel commented 6 years ago

Thank you for trying this extension out and for your feedback.

As temporary workaround: a vscode restart may help.

Are you using macOS or Linux? (There are some differences within the setup) Can you add some example code that break autocompletion for you?

vknabel commented 6 years ago

@thomas-alrek does your situation improve with 2.3.1-beta.0?. You need to download it from Github and install it locally.

Though completion for function argument names is not included yet.

thomas-alrek commented 6 years ago

@vknabel I will test it later and give you some feedback

vknabel commented 6 years ago

The potential fix is now released as 2.3.1

literalpie commented 6 years ago

I am having this issue with 2.3.1, and 2.3.1-beta.0 (I think I installed it right)

I notice that if I add an eroneous character to the path of swift.path.sourcekite, it does not change the behavior at all (I would expect some sort of error if it's not finding the correct files).

I followed the instructions in this comment from another issue, and received the expected output - I believe that confirms that I have sourcekite installed correctly.

edit: I am on Ubuntu 16.04, and using Swift 4.1.2

vknabel commented 6 years ago

@literalpie @thomas-alrek ok, fixed it with the officially released 2.4.1. Sorry for the delay.

More Detailed: The language server did immedeatly crash in prod builds, but worked fined in dev builds. I accidentially marked a runtime dependency as dev dependency in https://github.com/vknabel/vscode-swift-development-environment/commit/24038ec4f4cee0389ec032830138d039698397f4#diff-b9cfc7f2cdf78a7f4b91a753d10865a2R152. Therefore the dependency was not included in prod builds and nobody could see the error log because of https://github.com/Microsoft/vscode-languageserver-node/issues/319.

vknabel commented 6 years ago

I will keep this open until someone can confirm the fix.

literalpie commented 6 years ago

It is fixed for me! thank you very much