redhat-developer / redhat-developer/vscode-java

Java Maven Projects containing other nested Java Maven Projects not being recognized as Java Projects in 1.17

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

まだ誰も着手していません。

upstream
主要言語
TypeScript
スター
2.3k
フォーク
546
平均マージ
20時間 1分
マージ済み PR(30日)
11

説明

Description

I admit that our project structure is not standard, but it's how we've been working for many years. We have a java (war) project that contains many Java (jar) projects in a folder structure similar to the one below.

**root_java_project**
|-> pom.xml
|-> src
|-> **child_java_project_1**
      |-> pom.xml
      |-> src
|-> **child_java_project_2**
      |-> pom.xml
      |-> src
...
|-> child_java_project_n
      |-> pom.xml
      |-> src

Several on our team recently experienced this issue when we updated to Java Extension Pack to 1.17. It immediately ceased recognizing our ROOT project as being a legit java project. The child projects were fine. (note that the project hierarchy is only one level deep -- a root and it's children). Reverting back to 1.16 or earlier made the issue disappear.

Environment
  • Operating System: Mac OS Ventura 13.13.1
  • JDK version: 17 and 16
  • Visual Studio Code version: 1.77.3
  • Java extension version: 1.17
Steps To Reproduce
  1. Assume folder structure as shown above.
  2. Open an empty workspace
  3. click Add folder to workspace and select child_java_project_1
  4. project is added to workspace and it's recognized as a java project
  5. repeat for child_java_project_2 ... child_java_project_n
  6. all projects are recognized as java projects with full linking, debugging, etc, support.
  7. finally repeat for root_java_project. It shows up in the "Java Projects" but it doesn't recognize that there's a pom in that root folder and consequently doesn't capture it as being a legit java project.
  8. Revert back to 1.15 or 1.16 and it works.

I do see quite of few Stack Overflows in the Language Server Log file. Not sure if that's the cause.

VS Code Language Server Log file.txt
VSCode Client Logs.txt

Current Result
Expected Result
Additional Informations

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

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

はじめの一歩

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

調査の方向性

まず、issue に記載されているネストされた pom.xml ワークスペース構造を再現し、その後、報告された Stack Overflows について添付の VS Code Language Server Log と VSCode Client Logs を確認します。ルート Java プロジェクトが pom.xml とともに認識され、既存の子プロジェクトのサポートが Java extension 1.17 でも引き続き機能すれば完了です。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
java, vscode
領域
build-system, devtools
issue の種類
バグ
難易度
4/5
見積もり時間
3〜5日
活発さ
停滞
明瞭さ
説明が足りない
初心者へのやさしさ
25/100

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

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