truffleruby icon indicating copy to clipboard operation
truffleruby copied to clipboard

Can't set breakpoint in core library files

Open nirvdrum opened this issue 3 years ago • 2 comments

Similar to oracle/graal#5125, core library files won't appear in the "Loaded Scripts" section in the VS Code debugger. You can step into Ruby core library from a user function, which will cause the core library to load in the editor view. But, unlike with standard libraries, setting a breakpoint in this editor will not work when restarting the debugger. As a result, it's rather difficult to debug anything related to the core library.

nirvdrum avatar Sep 27 '22 14:09 nirvdrum

Are you using --core-load-path in this case or not? If yes, it's most likely the same as https://github.com/oracle/graal/issues/5125.

If not, then the Source doesn't actually have a file that VSCode can open, it's a file from inside truffleruby.jar, so then it sounds like a VSCode issue.

eregon avatar Sep 30 '22 15:09 eregon

With --core-load-path it worked fine when we tried recently, although one needs to first find such file and they are not all in Loaded Scripts.

eregon avatar Mar 21 '23 18:03 eregon