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

Can't get it working #12

Open
seantalts opened this issue Jan 24, 2019 · 3 comments
Open

Can't get it working #12

seantalts opened this issue Jan 24, 2019 · 3 comments
Labels
question Further information is requested

Comments

@seantalts
Copy link

I'm using Dune with this project: https://github.com/stan-dev/stanc3. Dune will build a bytecode or executable file in _build/default/. Here's my launch config:

{
    "version": "0.2.0",
    "configurations": [
        {
            "name": "OCaml",
            "type": "ocaml-debugger",
            "request": "launch",
            "program": "${workspaceRoot}/_build/default/stanc.exe",
            "console": "internalConsole",
            "stopOnEntry": true,
            "arguments": ["test/integration/examples-good/declarations.stan"]
        }
    ]
}

With the stanc.exe option, it just hangs forever. If I change it to stanc.bc, it does something for a second and then flashes red at the bottom. No errors I can find anywhere.

@hackwaly
Copy link
Owner

I just get it working! With this configuration:

{
    // Use IntelliSense to learn about possible attributes.
    // Hover to view descriptions of existing attributes.
    // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
    "version": "0.2.0",
    "configurations": [
        {
            "name": "OCaml",
            "type": "ocaml-debugger",
            "request": "launch",
            "program": "${workspaceRoot}/_build/default/stanc.bc",
            "dotMerlins": ["${workspaceRoot}/.merlin", "${workspaceRoot}/lib/.merlin"],
            "arguments": ["${workspaceRoot}/test/integration/examples-good/declarations.stan"],
            "console": "internalConsole",
            "stopOnEntry": false
        }
    ]
}

image

@seantalts
Copy link
Author

I'm still getting the same thing where it flashes red for a second and then nothing... I do have this in the "Extensions Output":

Fatal error: exception Not_found
Raised at file "hashtbl.ml", line 188, characters 6-21
Called from file "ocaml_debug_adapter/symbols.ml" (inlined), line 213, characters 2-37
Called from file "ocaml_debug_adapter/inspect.ml", line 54, characters 17-47
Called from file "src/core/lwt.ml", line 1929, characters 23-26
Re-raised at file "ocaml_debug_adapter/inspect.ml", line 52, characters 6-720
Re-raised at file "ocaml_debug_adapter/inspect.ml", line 50, characters 4-875
Re-raised at file "ocaml_debug_adapter/inspect.ml", line 76, characters 4-220
Re-raised at file "ocaml_debug_adapter/inspect.ml", line 97, characters 6-743

My dune dev profile is:

 (dev
  (flags (:standard -g)))

Perhaps that's not enough?

Thanks for your help!

@hackwaly
Copy link
Owner

I use earlybird 0.1.4 and ocaml 4.06.1

I didn't change your build file. But only run dune build stanc.bc.

@sim642 sim642 added the question Further information is requested label Jun 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants