redhat-developer / redhat-developer/vscode-java
"missing required Java project" error when opening android maven projects
还没有人认领这个 Issue。
- 主要语言
- TypeScript
- 星标
- 2.3k
- 派生
- 546
- 平均合并
- 20 小时 1 分钟
- 30 天内合并 PR
- 11
描述
Orginally reported by @Fr0stM0urne on https://github.com/microsoft/vscode-java-debug/issues/1329:
Trying to debug a java project (FlowDroid) using vscode. The project is built using maven. Getting this error when using "Run Debug" on the main function of a java file in the project:
Project 'soot-infoflow-summaries' is missing required Java project: 'soot'Tried cleaning java workspace and restarting java server but it did not fix the issue. These are the error logs of vscode java server:
!ENTRY org.eclipse.jdt.ls.core 4 0 2023-04-17 17:43:48.374 !MESSAGE Error occured while building workspace. Details: message: The project cannot be built until build path errors are resolved; code: 0; resource: ~/FlowDroid/soot-infoflow; message: Project 'soot-infoflow' is missing required Java project: 'soot'; code: 964; resource: ~/FlowDroid/soot-infoflow; message: The project was not built since it depends on soot-infoflow, which has build path errors; code: 0; resource: ~/FlowDroid/soot-infoflow-android; message: The project cannot be built until its prerequisite soot-infoflow-android is built. Cleaning and building all projects is recommended; code: 0; resource: ~/FlowDroid/soot-infoflow-cmd; message: The project was not built since it depends on soot-infoflow, which has build path errors; code: 0; resource: ~/FlowDroid/soot-infoflow-integration; message: Project 'soot-infoflow-summaries' is missing required Java project: 'soot'; code: 964; resource: ~/FlowDroid/soot-infoflow-summaries; message: The project cannot be built until build path errors are resolved; code: 0; resource: ~/FlowDroid/soot-infoflow-summaries;Steps To Reproduce
- Install sdkman using curl -s "https://get.sdkman.io" | bash
- Install maven using sdk install maven 3.8.7
- Clone FlowDroid using git clone https://github.com/secure-software-engineering/FlowDroid.git
- Set ANDROID_JARS environment variable. (See FlowDroid git repo for details)
- Install FlowDroid using mvn -DskipTests install. (See Flowdroid git repo for details)
- Open FlowDroid in VS code and go to soot-infoflow-cmd/src/soot/jimple/infoflow/cmd/MainClass.java.
Run/Debug the main functionEnvironment
- Operating System: Ubuntu 22.04.2 LTS x86_64
- JDK version: 1.8
- Visual Studio Code version: 1.77.3
- Java extension version: v0.25.10
- Java Debugger extension version: v0.49.1
Additional Information:
The missing project soot is located in ~/.m2/repository/org/soot-oss
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
从报告的 FlowDroid 复现以及 vscode-java language server 日志中的 Java 项目导入和构建路径错误开始。Maven 构建后打开 soot-infoflow-cmd/src/soot/jimple/infoflow/cmd/MainClass.java,并运行或调试其 main 函数来复现。完成的标准是解决缺少必需 Java 项目的错误,并且可以运行或调试 main 函数。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- java, vscode
- 领域
- developer-experience, tooling
- Issue 类型
- 缺陷
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 35/100