Skip to content

Commit

Permalink
Merge pull request #894 from johnnaegle/log_deserialization_errors
Browse files Browse the repository at this point in the history
Log an error message when a deserialization error occurs
  • Loading branch information
albus522 committed Mar 31, 2017
2 parents 51cf01f + 0602a6b commit ccbde3d
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/delayed/worker.rb
Original file line number Diff line number Diff line change
Expand Up @@ -233,6 +233,8 @@ def run(job)
job_say job, format('COMPLETED after %.4f', runtime)
return true # did work
rescue DeserializationError => error
job_say job, "FAILED permanently with #{error.class.name}: #{error.message}", 'error'

job.error = error
failed(job)
rescue Exception => error # rubocop:disable RescueException
Expand Down

0 comments on commit ccbde3d

Please sign in to comment.