Exception Notification Gem and Rails 3

后端 未结 17 2295
野趣味
野趣味 2021-01-30 05:16

I\'m trying to get this up and running, but I see \"uninitialized constant ExceptionNotifier\" whenever I start my server.

http://github.com/rails/exception_notificatio

17条回答
  •  渐次进展
    2021-01-30 05:58

    UPDATED ANSWER as of 3/14...

    You just need to do gem exception_notification in your gem file. No 'require' needed.

    Also, other changes just straight from the docs...

    "As of 4.x version the configuration syntax has changed. All email related options MUST BE nested under the :email key."

    like so...

    Whatever::Application.config.middleware.use ExceptionNotification::Rack,
      :email => {
        :email_prefix => "[Whatever] ",
        :sender_address => %{"notifier" },
        :exception_recipients => %w{exceptions@example.com}
      }
    

提交回复
热议问题