redhat-developer / redhat-developer/vscode-java
Gradle multi-module project breaks on reload, requires cleaning Java Language Server workspace every time
まだ誰も着手していません。
- 主要言語
- TypeScript
- スター
- 2.3k
- フォーク
- 546
- 平均マージ
- 20時間 1分
- マージ済み PR(30日)
- 11
説明
Description
I am working with a Java Gradle multi-module project in VS Code.
On the first load, the project fails with an error like:
The project was not built due to "xxx does not exist". Fix the problem, then try refreshing this project and building it since it may be inconsistent.
The suggested workaround is:
- Disable Gradle for Java extension
- Run "Java: Clean Java Language Server Workspace"
- Reload the project
This workaround does fix the problem, but only temporarily.
Problem
Every time I:
- reload the window, or
- close and reopen the project
I have to run "Java: Clean Java Language Server Workspace" again, otherwise the same error appears.
This makes working with the project very inconvenient.
Expected behavior
Once the project is cleaned and loaded successfully:
- It should stay in a consistent state
- Reloading or reopening the project should not require cleaning the Java Language Server workspace again
Actual behavior
- Project breaks again after reload
- Same error repeats
- Manual workspace cleaning is required every time
Environment
- VS Code
- Java multi-module Gradle project
- Java Language Server
- Gradle for Java extension enabled
Additional notes
This looks like a workspace cache or Gradle project import inconsistency issue.
It seems the Java Language Server does not correctly persist the resolved multi-module Gradle state across reloads.
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
まず、Gradle for Java 拡張機能と Java Language Server を使用して、Java のマルチモジュール Gradle プロジェクトで VS Code 上の失敗を再現します。"Java: Clean Java Language Server Workspace" を実行した後の初回ロードと再ロードまたは再オープンを比較します。ワークスペースを再度クリーンアップせずにプロジェクトの一貫性が保たれれば完了です。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- java, vscode
- 領域
- build-system, developer-experience, tooling
- issue の種類
- バグ
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 活発さ
- 活発
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 50/100