ruby / debug

Debugging functionality for Ruby
BSD 2-Clause "Simplified" License
1.14k stars 127 forks source link

DEBUGGER_.warn when skipping breakpoint because of RUBY_DEBUG_SKIP_PATH #996

Open marianosimone opened 1 year ago

marianosimone commented 1 year ago

Your proposal If a user sets a breakpoint in a path that is skipped because of RUBY_DEBUG_SKIP_PATH, it would be helpful to log a warning whenever the breakpoint would have stopped if the configuration wasn't there.

Additional context Sometimes I set up RUBY_DEBUG_SKIP_PATH for the most common case, but eventually end up having to dig deeper than usual, and add a breakpoint in a skipped path. After the debugger failing to stop there for a couple of times, I realize the problem and change the configuration.

It would be useful for the debugger to tell me that I have a breakpoint in a skipped path, to help me realize my error faster.

ko1 commented 1 year ago

warn on setting breakpoint?

marianosimone commented 1 year ago

It might be useful to have the warning when setting the breakpoint, too. However, I think that it should also show a warning when the breakpoint would have been hit, as setting RUBY_DEBUG_SKIP_PATH can happen in a different session (e.g: I set the breakpoint, work on things for a while, then configure RUBY_DEBUG_SKIP_PATH, and finally debug again)

ko1 commented 10 months ago

log level is next issue.