-
Notifications
You must be signed in to change notification settings - Fork 135
Undefined method '+' for nil #1134
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
Comments
I'm seeing the same problem on my end. |
Ditto |
I'm seeing the same. I'm able to reproduce the bug with: require 'debug'
class Whatever
def some_method
loop do
begin
raise "foo"
rescue => e
debugger
end
end
end
end
Whatever.new.some_method Just run it with ruby 3.4.1 and debug 1.10.0 and the error pops up. The issue doesn't happen with ruby 3.3.8. It seems that the regexp approach introduced in https://github.com/ruby/debug/pull/91/files#diff-372c5559dee1ab1a9fa1bace23d908bca7e295bfd24f10906a866529a7be6bc7 is not enough to cover all cases. For the ruby code above, the result of In ruby 3.3.8, I tested with ruby 3.5.0-preview1 and the string is also |
Your environment
ruby -v
: ruby 3.4.1 (2024-12-25 revision 48d4efcb85) +PRISM [x86_64-linux]rdbg -v
: rdbg 1.10.0Describe the bug
I'm trying to debug a separate issue, where it seems the WebConsole thread is hanging instead of reporting an error. When I connect to the puma server with
rdbg -A
, doth
to list the threads, thenth 13
(or whatever to pick the stuck thread), then dobt
, I get a big exception printed to the puma output:(formatted for readability, such as it is)
Also, when this happens, the console input for rdbg doesn't return. I have to hit
^C
, and it prints "Stop by SIGURG", and I'm able to input commands again.To Reproduce
Expected behavior
Successfully print the backtrace for a frame with
nil
forblock_loc
, or determine why a frame would have that.Additional context
It looks like its coming from thread_client.rb:85, so I printed out the values for
level
,block_loc
,args
andframe
:I'm able to get it to not blow up by changing the code like this:
But, I'm not sure why
block_loc
is nil (andlevel
is empty string), and if that indicates a larger problem.The text was updated successfully, but these errors were encountered: