-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Update lsp4J lib to newer version. #5292
Conversation
Fix bugs in language server dto generator. This bugs is not critical for current lsp4j 0.1.2 library. But dto generation fails if we update this library to 0.2.0. Fix some typos. Signed-off-by: Aleksandr Andrienko <aandrienko@codenvy.com>
Signed-off-by: Aleksandr Andrienko <aandrienko@codenvy.com>
Depends on #5290 |
Build # 2752 - FAILED Please check console output at https://ci.codenvycorp.com/job/che-pullrequests-build/2752/ to view the results. |
Build # 2762 - FAILED Please check console output at https://ci.codenvycorp.com/job/che-pullrequests-build/2762/ to view the results. |
PHP hover support is currently broken until lsp4j is updated (hover contains MarkedString instances, which are not supported on 0.1.2 |
…e into updateLSP4Jlib Signed-off-by: Yevhen Vydolob <evidolob@codenvy.com> # Conflicts: # wsagent/che-core-api-languageserver/src/main/java/org/eclipse/che/api/languageserver/service/TextDocumentService.java
Signed-off-by: Yevhen Vydolob <evidolob@codenvy.com>
Wip on the title should be removed no ? |
Build # 2950 - FAILED Please check console output at https://ci.codenvycorp.com/job/che-pullrequests-build/2950/ to view the results. |
…e into updateLSP4Jlib Signed-off-by: Yevhen Vydolob <evidolob@codenvy.com> # Conflicts: # plugins/plugin-languageserver/che-plugin-languageserver-ide/src/main/java/org/eclipse/che/plugin/languageserver/ide/LanguageServerExtension.java # plugins/plugin-languageserver/che-plugin-languageserver-ide/src/main/java/org/eclipse/che/plugin/languageserver/ide/editor/codeassist/CompletionItemBasedCompletionProposal.java # plugins/plugin-languageserver/che-plugin-languageserver-ide/src/main/java/org/eclipse/che/plugin/languageserver/ide/editor/codeassist/LanguageServerCodeAssistProcessor.java # wsagent/che-core-api-languageserver/pom.xml # wsagent/che-core-api-languageserver/src/main/java/org/eclipse/che/api/languageserver/launcher/LanguageServerLauncher.java # wsagent/che-core-api-languageserver/src/main/java/org/eclipse/che/api/languageserver/registry/ServerInitializerImpl.java # wsagent/che-core-api-languageserver/src/main/java/org/eclipse/che/api/languageserver/service/TextDocumentService.java
Signed-off-by: Yevhen Vydolob <evidolob@codenvy.com>
Build # 3056 - FAILED Please check console output at https://ci.codenvycorp.com/job/che-pullrequests-build/3056/ to view the results. |
…e into updateLSP4Jlib Signed-off-by: Yevhen Vydolob <evidolob@codenvy.com> # Conflicts: # wsagent/che-core-api-languageserver/src/main/java/org/eclipse/che/api/languageserver/registry/ServerInitializerImpl.java # wsagent/che-core-api-languageserver/src/main/java/org/eclipse/che/api/languageserver/service/TextDocumentService.java
Signed-off-by: Yevhen Vydolob <evidolob@codenvy.com>
Signed-off-by: Yevhen Vydolob <evidolob@codenvy.com>
hover.setContent(content); | ||
|
||
return hover; | ||
Promise<OrionHoverOverlay> then = promise.then((Function<Hover, OrionHoverOverlay>)arg -> { |
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.
I think writing `(Hover arg)->....' would make the generic types clear and it feels nicer than a cast.
// plain markdown text | ||
contents.add(dto.getLeft()); | ||
} else { | ||
contents.add(dto.getRight().getLanguage()); |
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.
I think the "language" field is supposed to help render the content, not be displayed. Should we simply ignore the tag if we don't properly handle it?
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.
We(Orion) properly handle it
@@ -113,11 +116,13 @@ public SignatureHelpOptions getSignatureHelpProvider() { | |||
return result; | |||
} | |||
|
|||
public TextDocumentSyncKind getTextDocumentSync() { | |||
public Either<TextDocumentSyncKind, TextDocumentSyncOptions> getTextDocumentSync() { |
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.
Do we really need to merge the whole thing, or can we just return TextDocumentSyncKind here? I don't think we're doing anything on the client side with it.
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.
But for new version of the LS we should support all sync options
if (CLIENT_CAPABILITIES == null) { | ||
CLIENT_CAPABILITIES = new ClientCapabilities(); | ||
WorkspaceClientCapabilities workspace = new WorkspaceClientCapabilities(); | ||
workspace.setApplyEdit(false); //Change when support added |
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.
I believe we can omit anything that is false. I find it confusing to set stuff that is default anyway.
@@ -99,8 +101,8 @@ public void configureMethods() { | |||
dtoToDtoList("references", ReferenceParams.class, LocationDto.class, this::references); | |||
dtoToDtoList("onTypeFormatting", DocumentOnTypeFormattingParams.class, TextEditDto.class, this::onTypeFormatting); | |||
|
|||
dtoToDto("completionItem/resolve", ExtendedCompletionItem.class, ExtendedCompletionItemDto.class, this::completionItemResolve); | |||
dtoToDto("documentHighlight", TextDocumentPositionParams.class, DocumentHighlightDto.class, this::documentHighlight); | |||
dtoToDto("completionItem/resolve", ExtendedCompletionItem.class, ExtendedCompletionItem.class, this::completionItemResolve); |
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.
Did you test this? Why is it different from the lines above (LocationDto, TextEditDto, etc.)?
Build # 3060 - FAILED Please check console output at https://ci.codenvycorp.com/job/che-pullrequests-build/3060/ to view the results. |
Signed-off-by: Yevhen Vydolob <evidolob@codenvy.com>
Build # 3061 - FAILED Please check console output at https://ci.codenvycorp.com/job/che-pullrequests-build/3061/ to view the results. |
* eclipse-che#5360 Upgrade LSP4J library version to 0.2.0 Signed-off-by: Yevhen Vydolob <evidolob@codenvy.com>
What does this PR do?
Update lsp4j to 0.2.0 version