When I debug rails code, I sometimes set a binding.pry on a certain place that is triggered too often to be debugged, e.g. a loop.
Then I use the disable-pry command to step out of it and let the rest of the program continue. But now when I make another request to the rails server, my breakpoints aren't triggered anymore. And this of course makes sense, as I called disable-pry before.
The only known solution to me is to restart the whole server. But this becomes painful after a while, as reloading the whole environment can be pretty slow.
Is there a way to re-enable pry after having it disabled with disable-pry without restarting the whole ruby process?
continueinstead ofdisable-pryto step out of your breakpoint and let the rest of the program run. This way you're not disablingpry.Ctrl-D) and the loop has thousand of runs it could take a while...binding.pryonly once (using an index for example). Would love to know if there's a better solution!