You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm not sure it's at fault of the debugger as that's how ENV vars are passed to child processes. But perhaps we can do something from the debugger to prevent it?
To Reproduce
bar.rb
puts"bar"
target.rb
result=`ruby bar.rb`puts(result)
terminal1
RUBYOPT=-rdebug/open ruby -Ilib target.rb
terminal2
rdbg -A
Expected behavior
The second process shouldn't start a debugging session.
Describe the bug
Some criteria for this issue:
RUBYOPT=-rdebug/opento load the debugger in remote mode.system("bundle exec rake")When the above happens at the same time, it'll trigger double debugging sessions. I recorded a video to demo this:
2022-06-26.12.27.14.mov
This is annoying because the second session starts independently and hangs the program, until we connect to and disable it.
And this can happens to Rails apps.
I'm not sure it's at fault of the debugger as that's how ENV vars are passed to child processes. But perhaps we can do something from the debugger to prevent it?
To Reproduce
bar.rb
target.rb
terminal1
terminal2
Expected behavior
The second process shouldn't start a debugging session.