src/main/resources excluded from classpath for Gradle subprojects with generated source directories
@snjeza ya está trabajando en esto.
Desde el 20/4/2026.
Evaluación
Este issue todavía no se ha evaluado.
Descripción
Describe the bug
After updating the VS Code extension to 1.54.0, I started seeing issues with my Java application re: Liquibase. The specific error was a failur to run with Failed to configure a DataSource: 'url' attribute is not specified. but after some digging with the help of an LLM it seems that the cause was that excluding='**' was being added to the entries in .classpath/src/main/resources.
It only happened with one subproject; the agent sugested that the excluding is only added when there is a generated source dir on the build path (like build/generated/sources/dgs-codegen).
To Reproduce
The LLM created these steps and I agree that they describe my situation:
- Open a multi-module Gradle project in VS Code with redhat.java 1.54.0
- Ensure at least one subproject has a generated source directory on its build path (e.g. DGS codegen, annotation processing)
- Wait for "Java: Ready"
- Open the generated .classpath for that subproject in the JDT workspace storage (at ~/Library/Application Support/Code/User/workspaceStorage//redhat.java/jdt_ws/.metadata/.plugins/org.eclipse.core.resources/.projects//.classpath)
- Observe that src/main/resources has excluding="**" on its entry, while a sibling subproject without generated sources does not
The practical consequence for Spring Boot projects: the app fails to start because application.yml is not on the classpath (Tomcat defaults to port 8080, datasource properties are unresolved).
Unfrotunately I don't have a sample project to attach; mine is a closed source application.
Expected behavior
Just like in 1.53.0, src/main/resources doesn't use excluding="**", and resource files are copied to the output dir during compilation so they're available at runtime.
Screenshots
N/A
Environment
- Operating System: macOS 15.6 (Apple Silicon, arm64)
- JDK version: 17.0.18
- Visual Studio Code version: 1.116.0
- Java extension version: 1.54.0 (doesn't work) / 1.53.0 (works)
Additional Information
The excluding prop is added with both java.gradle.buildServer.enabled: "auto" and java.gradle.buildServer.enabled: "off"
- Lenguaje dominante
- TypeScript
- Estrellas
- 2.3k
- Forks
- 547
- Merge medio
- 20 h 9 min
- PR fusionados (30 d)
- 10
Guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de redhat-developer/vscode-java
-
bug
Dificultad 1/5 Menos de una hora Aptitud para principiantes 85/100
redhat-developer/vscode-java#4509 ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
redhat-developer/vscode-java#4426 ·
-
bug
Dificultad 4/5 3-5 días Aptitud para principiantes 45/100
redhat-developer/vscode-java#4506 · 3 comentarios · 4 reacciones ·
-
bug
Dificultad 4/5 3-5 días Aptitud para principiantes 45/100
redhat-developer/vscode-java#4505 · 2 comentarios · 2 reacciones ·
-
Dificultad 4/5 3-5 días Aptitud para principiantes 52/100
redhat-developer/vscode-java#4504 · 3 comentarios · 1 reacción ·
Todos los issues de redhat-developer/vscode-java
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
safetrustcr/dApp-SafeTrust#426 ·
-
area:workflow bug ready-for-agent
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
fil-donadoni/tolaria#4409 ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
Fission-AI/OpenSpec#1960 ·
-
Add dependabot Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
corsairdev/corsair#1764 ·