hackwaly / vscode-ocaml-debugger

OCaml debugger for VS Code
14 stars 4 forks source link

Debug adapter process has terminated unexpectedly (read error) #2

Closed villesau closed 5 years ago

villesau commented 5 years ago

Hi, I have following run config:

{
    "version": "0.2.0",
    "configurations": [
        {
            "name": "OCaml",
            "type": "ocaml-debugger",
            "request": "launch",
            "program": "${workspaceRoot}/a.out",
            "console": "internalConsole",
            "stopOnEntry": false
        }
    ]
}

Following program:

helloworld.ml: print_string "Hello world!\n";;

and compiled with command ocamlc -g helloworld.ml

Ocaml version: 4.07.0 earlybird: 0.1.1

And I'm getting the error Debug adapter process has terminated unexpectedly (read error) and Debug adapter process has terminated unexpectedly (exit code: 1) in VSCode. Anyhow there is no any further details. Any suggestions what could be the culprit? If the information provided is not enough, could the extension be made to print more info when it's failing so that I could provide proper info?

I pretty much followed the instructions from this message: https://github.com/hackwaly/vscode-ocaml/issues/116#issuecomment-331698504

hackwaly commented 5 years ago

Did you try it in 4.06? I haven't test it under 4.07.

Try add no_debug:true to run see if it still exit unexpectly.

villesau commented 5 years ago

Yep, same errors with 4.06 and "no_debug": true :/

villesau commented 5 years ago

@hackwaly got it working! The problem was that my VSCode was in downloads folder instead applications folder: https://github.com/Microsoft/vscode/issues/7426#issuecomment-425093469