microsoft / microsoft/vscode-java-pack

Opening project as workspace causes language server to ignore java.jdt.ls.vmargs

オープン
#988 コメント 5 件 リアクション 0 件 担当者 1 名 GitHub で見る

@testforstephen がすでに取り組んでいます。

2022年5月5日 から。

ai-triaged bug lombok settings
主要言語
TypeScript
スター
352
フォーク
166
平均マージ
17時間 47分
マージ済み PR(30日)
32

説明

I can't reproduce this on all workspaces, but for a strange reason some projects have issues with Lombok auto-generated methods when using the Java Extension Pack where the language server fails to recognize Lombok auto-generated methods.

The root cause appears to be that the java.jdt.ls.vmargs global setting is ignored, and the language server JVM is launched without the -javaagent:/path/to/lombok.jar that the VS Code Lombok extension injects. When opening the same affected project as a folder instead of as a workspace, the vmargs are injected correctly.

Environment:

  • VS Code Version: v1.66.2
  • Extension Version: v0.22.4
  • JDK Type & Version: Termurin 18
  • OS Type & Version: Mac

Step to Reproduce:

  1. Open project as workspace
  2. Enable/install Java Extension Pack and Lombok extensions
  3. Write a POJO making use of @Getter and @Setter Lombok annotations
  4. Try to call the getters of said POJO from another class

Expected Behavior:
Code intellisense/autocomplete shows Lombok-generated getters and setters, and code written calling the getters and setters has no errors.

Actual Behavior:
VS Code claims the getters and setters are undefined methods, and will not build or compile the project. Maven can compile the code with a mvn clean compile normally.

Related Issues:
Possibly related to https://github.com/redhat-developer/vscode-java/issues/1802

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

評価

この issue はまだ評価されていません。

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。