Steps to reproduce
Given: ExceptionNotifier is configured with:
ignore_notifier_if: {
email: ->(env, exception) { ... }
},
And an exception notification is manually sent such as through a background worker with:
rescue => e
ExceptionNotifier.notify_exception(e)
end
Expected behavior
The ignore_notifier block should be called and respected.
Actual behavior
The ignore_notifier block is not called nor respected. This is likely because the ignore block is only set via Rack, so any non-Rack usages of ExceptionNotifier will not retain the ignore settings.
System configuration
Rails version:
Rails v6+
Ruby version:
Ruby 2.7