-
Notifications
You must be signed in to change notification settings - Fork 426
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
Make backtrace cleaning optional #242
Make backtrace cleaning optional #242
Conversation
This adds a new config `config.exception_notification.clean_backtrace` (defaults to `true`) for changing whether backtraces should be cleaned. Also fixed a bug where the backtrace of background exceptions are not ran through the backtrace cleaner currently. Fixes smartinez87#228
(Travis failure seems unrelated, #237 had the same problem. Seems like we just need to lock down the sidekiq version on the older Gemfiles) |
Any chance that this can be merged at some point ? |
@vala are you still experiencing problems with the backtrace? |
+1 Having this would be very nice, right now (specially with Sidekiq) I get very little info and would really like to have the full backtrace sometimes. |
+1 the full stack trace would save you some time of log digging when you need more info. |
@smartinez87 Sorry for the delay, but the backtrace is still cleaned up in the latest versions of Exception Notification for me |
b2b9f49
to
c1976c8
Compare
closing this PR in favor of #328 |
Hello!
This is a starting point to fix #228. It adds a new config
clean_backtrace
(defaults totrue
) for changing whether backtraces should be cleaned.Also fixed a bug where the backtrace of background exceptions are not ran through the backtrace cleaner currently – I'm unsure if this was intentional, but it was easier to "fix" this so that the test would pass. If that's unacceptable, feel free to pick it up from here and improve the code.
To maintain the current behavior, the new option is defaulted to
true
. However, personally, I feel that this whole feature (backtrace cleaning) is of dubious values in these exception emails. I came across this when helping a client debug an error they are encountering, but unfortunately the error is originated from a gem so I didn't have any backtrace to look at. It seems like you would always want to have more information in these reports... I'm not sure if there's much value in having the option to clean the backtrace in the first place in this context.The backtrace cleaning code is also only used in the
EmailNotifier
, so if this is staying, it should probably be moved up one layer so that it would be consistent across theWebhookNotifier
(for example) and the chat notifiers as well (in theory, the cleaner could remove some of the top frames in the backtrace as well).Like I said, this is only a starting point, so if it doesn't fit your needs for some reason, feel free to pick it up and improve it or reimplement in another way. Would love to see this feature go into the master branch eventually!
Thanks for reviewing this, hope it helps! ❤️ 💛 💚 💙 💜
Fixes #228