Skip to content

[BUG]: Cannot find any debuggable program #1388

@owl-from-hogvarts

Description

@owl-from-hogvarts

I run a program by next command line:

java -agentlib:jdwp=transport=dt_socket,server=y,suspend=y,address=54583 -jar ./target/cli-0.1.3-jar-with-dependencies.jar

as error message suggests:
image

Environment
  • Operating System: Arch Linux
  • JDK version: 17.0.8.1
  • Visual Studio Code version: 1.81.1
  • Java extension version: v1.21
  • Java Debugger extension version: v0.54,0
Steps To Reproduce
  1. Setup simple maven program. Add next configuration to .vscode/launch.json:
    {
      "type": "java",
      "request": "attach",
      "name": "Attach by Process ID",
      "processId": "${command:PickJavaProcess}", // notice this line
    },
  1. launch java in terminal (external or internal does not metter) with command like from above (suspend flag also does not change anything)
  2. try launch "Attach by Process ID" configuration

[attach a sample project reproducing the error]
attach logs
client.log.2023-09-05.log
vscode-app-1693937515156.log

Sample project with built java classes

Current Result

Selecting process for debugging by processId can't find debuggable process.
Connection via hostname+port works well. processId does not work even if pid number is provided.

Expected Result

Selecting process by java process picker or pid works

Additional Informations

VScode is installed via snapd
Node js and other debuggers works well.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions