Skip to content

Commit

Permalink
chore: Add verbose errors for IMAP email channels (#9116)
Browse files Browse the repository at this point in the history
  • Loading branch information
sojan-official committed Mar 16, 2024
1 parent 29e44ac commit fd832d7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/jobs/inboxes/fetch_imap_emails_job.rb
Expand Up @@ -12,10 +12,10 @@ def perform(channel)
process_email_for_channel(channel)
end
rescue *ExceptionList::IMAP_EXCEPTIONS => e
Rails.logger.error e
Rails.logger.error "Authorization error for email channel - #{channel.inbox.id} : #{e.message}"
channel.authorization_error!
rescue EOFError, OpenSSL::SSL::SSLError, Net::IMAP::NoResponseError, Net::IMAP::BadResponseError, Net::IMAP::InvalidResponseError => e
Rails.logger.error e
Rails.logger.error "Error for email channel - #{channel.inbox.id} : #{e.message}"
rescue LockAcquisitionError
Rails.logger.error "Lock failed for #{channel.inbox.id}"
rescue StandardError => e
Expand Down

0 comments on commit fd832d7

Please sign in to comment.