-
Notifications
You must be signed in to change notification settings - Fork 410
Description
[provide a description of the issue]
Environment
- Operating System: MacOS 10.14.6
- JDK version: 1.8.0_151
- Visual Studio Code version: 1.42.1
- Java extension version: Extension Pack 0.8.1
- Java Debugger extension version: I can't figure out how to determine this: "debugger for Java" doesn't appear in list of installed extension
Steps To Reproduce
-
[step 1]
-
[step 2]
The issue is that upon launching a debugger, VS Code runs this command line:
~/Sync/projects/music/music-03:cd /Users/Mike/Sync/projects/music/music-03 ; /Library
/Java/JavaVirtualMachines/jdk1.8.0_151.jdk/Contents/Home/bin/java
-agentlib:jdwp=transport=dt_socket,server=n,suspend=y,address=localhost:58363
-Dfile.encoding=UTF-8 @/var/folders/pn/3p41p2fj14d50n707c7x2p4c0000gn
/T/cp_90sfb6m3zinsbhwyvyknqb5hv.argfile ptcs.App
And I get this error:
Error: Could not find or load main class
@.var.folders.pn.3p41p2fj14d50n707c7x2p4c0000gn.T.cp_90sfb6m3zinsbhwyvyknqb5hv.argfile
I have no idea where the command line came from... as far as I can tell, it's illegal on Mac to use an "at sign" @ in the command line, and java is trying to interpret that as the main class, so something is wrong.
[attach a sample project reproducing the error]
attach logs
Create Maven project in VS Code... install all Java extensions.
Work with project for several months, making many changes. Not sure what details are significant.
Here's the project:
music-03.zip
Try to launch debugger in maven project, using the default launch.json. I'm not using the "current file" one, but using the (Launch) - App config.
"version": "0.2.0",
"configurations": [
{
"type": "java",
"name": "Debug (Launch) - Current File",
"request": "launch",
"mainClass": "${file}"
},
{
"type": "java",
"name": "Debug (Launch)-App",
"request": "launch",
"mainClass": "ptcs.App",
"projectName": "music-03"
}
]