Capturing local variables in Ruby

Hi Sentry,

I’m a Python dev who now uses Ruby at work and noticed that unlike the Python one, the Ruby version of the Sentry client(raven-ruby) doesn’t(and is not capable to) send the captured local variables for each stack frame, which made debugging much harder than I was with Python + Sentry.

I tried to follow up with this matter, and figured out that we had several attempts to implement this but somehow it didn’t end up getting merged.

Issue: https://github.com/getsentry/raven-ruby/issues/7
PR: https://github.com/getsentry/raven-ruby/pull/337

I got some answers from the IRC channel that capturing local variables was too expensive, so we ended up doing some less expensive approach, but the work was undone.

I want to follow up with this issue and if possible, contribute to this part!
Any feedback/suggestion is much appreciated!

Thanks,

I’m not even really concerned about the “expensiveness” of capturing local variables, mostly I’m concerned about the stability. Pretty much every solution we’ve tried relies on semi-public APIs which could SEGV at any time.