Created
October 5, 2015 16:13
-
-
Save biske/29311825ba6e2ee02b45 to your computer and use it in GitHub Desktop.
Find delayed job fail jobs with certain error
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Delayed::Job.where(queue: 'roundabout').where("last_error ilike ?", "%undefined method `email' for nil:NilClass\n/app/app/mailers/assessment_criterion_mailer.rb:12:in `notify_participant'%").order(updated_at: :desc).each do |job| | |
p YAML.load(job.handler).args.first | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Delayed::Job.where(queue: 'legacy').where("last_error ilike ?", "%undefined method `call' for%").order(updated_at: :desc).each do |job|
p "_"
p job.handler
p "_"
end