Sha256: 3c313f32c2885e17180ccf248dc35081777df45c7118c8c13faad109997b45a8

Contents?: true

Size: 575 Bytes

Versions: 73

Compression:

Stored size: 575 Bytes

Contents

require "net/http"
require "net/smtp"

# Example:
#   begin
#     some http call
#   rescue *HTTP_ERRORS => error
#     notify_hoptoad error
#   end

HTTP_ERRORS = [
  EOFError,
  Errno::ECONNRESET,
  Errno::EINVAL,
  Net::HTTPBadResponse,
  Net::HTTPHeaderSyntaxError,
  Net::ProtocolError,
  Timeout::Error,
]

SMTP_SERVER_ERRORS = [
  IOError,
  Net::SMTPAuthenticationError,
  Net::SMTPServerBusy,
  Net::SMTPUnknownError,
  Timeout::Error,
]

SMTP_CLIENT_ERRORS = [
  Net::SMTPFatalError,
  Net::SMTPSyntaxError,
]

SMTP_ERRORS = SMTP_SERVER_ERRORS + SMTP_CLIENT_ERRORS

Version data entries

73 entries across 73 versions & 10 rubygems

Version Path
suspenders-1.41.0 templates/errors.rb
welaika-suspenders-2.25.0 templates/errors.rb
cosmit-suspenders-1.36.13 templates/errors.rb
suspenders-1.40.0 templates/errors.rb
suspenders-1.39.0 templates/errors.rb
voyage-1.0 templates/errors.rb
cosmit-suspenders-1.36.12 templates/errors.rb
cosmit-suspenders-1.36.11 templates/errors.rb
cosmit-suspenders-1.36.3 templates/errors.rb
cosmit-suspenders-1.36.2 templates/errors.rb
cosmit-suspenders-1.36.1 templates/errors.rb
cosmit-suspenders-1.36.0 templates/errors.rb
hosentrager-1.39.1 templates/errors.rb
suspenders-1.38.1 templates/errors.rb
welaika-suspenders-2.24.0 templates/errors.rb
suspenders-1.38.0 templates/errors.rb
suspenders-ocs-0.0.10 templates/errors.rb
suspenders-ocs-0.0.8 templates/errors.rb
suspenders-ocs-0.0.7 templates/errors.rb
suspenders-ocs-0.0.6 templates/errors.rb