redhat-developer / redhat-developer/vscode-java
"No build tools" Java projects auto-import skipped due to presence of "build tools" Java projects in same workspace
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 2.3k
- Forks
- 546
- Avg merge
- 20h 1m
- Merged PRs (30d)
- 11
Description
Describe the bug
Java projects without build tools are being skipped during auto-import due to the presence of Java projects with build tools in the same workspace. This results in missing imports and project configuration issues.
To Reproduce
Steps to reproduce the behavior:
- Create a workspace containing both Java projects with build tools (e.g., Maven, Gradle) and Java projects without build tools.
- Clean the Java language server workspace to trigger auto-import on startup.
- The Java projects without build tools fail to auto-import properly or are ignored/skipped by the extension, as they are not visible in the list of projects to import and do not import at all when opening any Java file in such projects.
Expected behavior
Java projects without build tools should be available as options to select in the import java projects list, allowing a non-build-tooled Java project to be imported correctly instead of skipped.
Environment
- Operating System: Windows
- JDK version: 21
- Visual Studio Code version: 1.111.0
- Java extension version: 1.53.0
Additional Information
When opening a Java file in a Java project without build tools, it will be automatically imported and added to the Java projects list, therefore auto-importing works fine as long as build tools projects aren't in the same workspace.
The best solution seems to be to add these types of projects to the list of importable Java projects and allow selection of non-build-tooled projects.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the issue in Visual Studio Code with a workspace containing both Maven or Gradle projects and projects without build tools, then clean the Java language server workspace to trigger auto-import on startup. Trace the importable-project list and verify that non-build-tooled projects appear there and can be selected and imported without opening a Java file first.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, typescript, vscode
- Domain
- developer-experience, tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100