Skip to content
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

Email errors in ActionMailer::DeliveryJob are not reported #487

Closed
maxim opened this issue Jun 9, 2016 · 5 comments
Closed

Email errors in ActionMailer::DeliveryJob are not reported #487

maxim opened this issue Jun 9, 2016 · 5 comments
Assignees

Comments

@maxim
Copy link

maxim commented Jun 9, 2016

The docs recommend to add this to your ActiveJob jobs:

include Rollbar::ActiveJob

However, rails has a built-in job called ActionMailer::DeliveryJob which is used when you call deliver_later on your action mailer emails. Currently errors in that job are not being reported.

I think it makes sense for this gem to automatically hook into that job as part of Rails integration.

@jondeandres
Copy link
Contributor

@maxim yes, we will need to add our module to ActionMailer::DeliveryJob class. You can do this now for yourself until we do it

ActionMailer::DeliveryJob.class_eval do 
  include Rollbar::ActiveJob
end

Thanks,

@sandlerr
Copy link

sandlerr commented Oct 2, 2016

@jondeandres just wondering why this was closed? It looks like this still needs to be manually included?

@jondeandres
Copy link
Contributor

@sandlerr you are right, reopening. Thanks!

@defkode
Copy link

defkode commented May 5, 2018

this can also written even shorter:

ActionMailer::DeliveryJob.include Rollbar::ActiveJob

waltjones added a commit that referenced this issue Feb 19, 2019
Issue #487: Automatically add Rollbar::ActiveJob to ActionMailer::DeliveryJob
@grzuy
Copy link

grzuy commented Dec 24, 2020

I see this was fixed a while ago (thanks!) but I suspect this is no longer working for Rails v6.0+ because of Rails switching from ActionMailer::DeliveryJob to ActionMailer::MailDeliveryJob?

jaredbeck added a commit to jaredbeck/rollbar-gem that referenced this issue Oct 27, 2022
waltjones pushed a commit that referenced this issue Jan 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests