redhat-developer / redhat-developer/vscode-java
vscode-java tries to compile temporary files
オープン
まだ誰も着手していません。
bug
compile
priority/P1
- 主要言語
- TypeScript
- スター
- 2.3k
- フォーク
- 546
- 平均マージ
- 20時間 1分
- マージ済み PR(30日)
- 11
説明
It seems like the extension automatically adds temporary files to the build path and then never removes them.
Environment
- Operating System: Windows
- JDK version: 1.8
- Visual Studio Code version: 1.28.1 (and previous versions)
- Java extension version: 0.32.0
Steps To Reproduce
- Create a maven (probably the same with gradle) based java project
- Add to git repository
- Compile, debug, check that everything works.
- Right-click a file, compare to previous version
- Debug the project - it will fail to compile.
- Check extension log, you will see a lot of errors of unable to resolve dependencies and also that the type that was in the file you compared is already defined.
Bonus section - Close VS Code
- Open again, with same project
- Try to debug - it will still fail to compile.
- Check the extension log, you will see a single error, something like:
Error occured while building workspace. Details:
message: The project was not built since the source file /jdt.ls-java-project/src/com/test/test/testfile-2dfd1f2d__202220CoCQDMrqr9JO.java could not be read;code: 0
Current Result
Whenever I compare a file to it's previous version, vscode cannot compile my project anymore
Expected Result
To only compile files that are in the path of the project, not temporary files.
Additional Informations
This will most problably also resolve #390
Workaround - close Code, delete workspace cache, open project again.
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
記載された比較およびデバッグ手順を使用して、Maven ベースの Java プロジェクトで問題を再現し、その後、拡張機能のログとワークスペースキャッシュの動作を調査します。一時的な比較ファイルがプロジェクトのビルドパスに入る経路を追跡します。完了条件は、VS Code の再起動後も含め、未解決の依存関係や重複型エラーなしでデバッグが成功することです。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- java, vscode
- 領域
- developer-experience, tooling
- issue の種類
- バグ
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 35/100