Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Vscode Spring Boot Tools 1.39.0 prevents Java project from Running/Debugging #847

Closed
jaysonsosweet opened this issue Sep 16, 2022 · 11 comments
Labels
for: vscode something that is specific for VSCode type: bug

Comments

@jaysonsosweet
Copy link

jaysonsosweet commented Sep 16, 2022

Describe the bug
This last vscode Spring Boot Tools 1.39.0, prevents vscode from running or debugging a java project.
When launching Run/Debug a java project "Activating extensions" appears briefly in status bar then fades, and then nothing.
The whole process stops there without any log in the output console.

Downgrading to the v1.38.0 solves the problem.
Spent the entire day work to find out what was causing this nonsense.

To Reproduce
Upgrade to Spring Boot Tools 1.39.0. Then start a debugging session on your java project.

@jaysonsosweet jaysonsosweet changed the title Vscode Spring Boot Tools 1.39.0 prevent Java project from Running/Debugging Vscode Spring Boot Tools 1.39.0 prevents Java project from Running/Debugging Sep 16, 2022
@pelmato
Copy link

pelmato commented Sep 19, 2022

Same problem here, back to 1.38.0 to continue working.

@BoykoAlex
Copy link
Contributor

Looks very odd... does this happen with any project? How about spring-petclinic? Are you able to launch it from vscode?
Don't recall us adding anything to our tweaks to the launch in VSCode for 1.39...
Anything interesting in Boot LS log? What is the VSCode version? Can you see the java process for the java project after all? Does it launch? If yes, what are the JVM args?
One thing to try would be to find Boot-java › Live-information › Automatic-connection under Spring Boot Tools -> Features settings and turn it off. Any difference?

@pelmato
Copy link

pelmato commented Sep 19, 2022

Actually I can no longer reproduce after uninstalling/reinstalling all spring boot extensions.

@jaysonsosweet
Copy link
Author

jaysonsosweet commented Sep 20, 2022

Here's my VSCode infos:
Version: 1.71.2 (user setup)
Commit: 74b1f979648cc44d385a2286793c226e611f59e7
Date: 2022-09-14T21:03:37.738Z
Electron: 19.0.12
Chromium: 102.0.5005.167
Node.js: 16.14.2
V8: 10.2.154.15-electron.0
OS: Windows_NT x64 10.0.19042
Sandboxed: No

Was using latest version from all the Spring Boot Extension Pack, that is Sprint Boot Tools, Spring Initializr Java Support, Spring Boot Dashboard.

At first I did uninstalled/reinstalled all of them without any success. Then I downgraded one notch each of them one at a time until if found out Spring Boot Tools was the culprit.

Just have this arg in my launch.json : "args": "--spring.profiles.active=local"

Noticed as well that Spring Boot Dashboard was endlessly and unsuccessfully trying to find a project.

@jaysonsosweet
Copy link
Author

jaysonsosweet commented Sep 20, 2022

One thing to try would be to find Boot-java › Live-information › Automatic-connection under Spring Boot Tools -> Features settings and turn it off. Any difference?

Let me try setting off that setting, and I'll come back to you.

Edit:
Well no luck... Got back to 1.39.x. Switch off automatic-connection but no success.

@BoykoAlex
Copy link
Contributor

I've tried VSCode on Windows with almost identical info. The only difference my Win was 10.0.19041 and yours is 10.0.19042. It worked just fine for me. The only suspicious thing is inability to find a project by Spring Boot Dashboard. Perhaps it can't get the classpath for a project which means Boot LS probably can't get the classpath either...
Therefore:

  1. I'd like to see the spring boot ls log file contents.
  2. Does this happen for any java project? Is this a specific java project? Is it a spring boot application or plain java app? Can you reproduce the issue with spring-petclinic app?
  3. What's the java runtime used to launch spring bool ls and jdt ls? Do you have a value for "java.jdt.ls.java.home" and/or "spring-boot.ls.java.home"? Otherwise java running the process should be java 17 embedded into vscode java extension. Please verify this with jconsole
  4. Anything different if you launch plain java app (non spring app)?

@BoykoAlex
Copy link
Contributor

Should be fixed with ec8a5a8

@eb-kmd
Copy link

eb-kmd commented Oct 14, 2022

I still have this issue in 1.39.0

@martinlippert
Copy link
Member

@eb-kmd You can download the latest nightly snapshot build and install that manually in order to see if the fix that Alex mentioned works for you. You can find the link to the latest VSIX file at the bottom of this page: https://dist.springsource.com/snapshot/STS4/nightly-distributions.html.

@martinlippert
Copy link
Member

The official release is scheduled to be published sometime later this week.

@baincd
Copy link

baincd commented Nov 23, 2022

I suspect this was the same issue as #893

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
for: vscode something that is specific for VSCode type: bug
Projects
None yet
Development

No branches or pull requests

6 participants