Using version 2.6.0 with rails 3.2.2, ruby 1.8.7.
Finally started using the background_exception_notification section and ran into an error where it looks like my custom section is not being found..
I am using my own custom section (from environment.rb):
:sections => %w{instructions_for_support} + ExceptionNotifier::Notifier.default_sections,
:background_sections => %w{instructions_for_support} + ExceptionNotifier::Notifier.default_background_sections
}
(other parts are set elsewhere).
The instructions_for_support
partial is being found just fine when I use the exception_notifier
method, but it's not finding it when I use background_exception_notification
. To investigate I renamed the partial so it wouldn't be found.
With exception_notification
I get this message:
Missing partial exception_notifier/instructions_for_support with {:formats=>[:text], :locale=>[:en], :handlers=>[:coffee, :erb, :builder]}. Searched in:
* "/home/bselig/.rvm/gems/ruby-1.8.7-p334@Upgrade32/gems/exception_notification-2.6.0/lib/exception_notifier/views"
* "/mnt/dev_shared_codebase/Upgrade_Rails_32x/app/views"
and with background_exception_notification
I get this error:
Missing partial exception_notifier/instructions_for_support with {:formats=>[:text], :locale=>[:en], :handlers=>[:coffee, :erb, :builder]}. Searched in:
* "/home/bselig/.rvm/gems/ruby-1.8.7-p334@Upgrade32/gems/exception_notification-2.6.0/lib/exception_notifier/views"
As you can see, exception_notification
is searching in my app's views folder while background_exception_notification
is not.
The difference seems to be this line:
self.append_view_path Rails.root.nil? ? "app/views" : "#{Rails.root}/app/views" if defined?(Rails)
which is at the beginning of exception_notification
but not background_exception_notification
.
Am I misunderstanding something or is this just an oversight in the code?