Exception: RubyPi::Error

Inherits:
StandardError
  • Object
show all
Defined in:
lib/ruby_pi/errors.rb

Overview

Base error class for all RubyPi exceptions. Rescue this to catch any error originating from the RubyPi framework.

Examples:

Catching all RubyPi errors

begin
  provider.complete(messages: msgs)
rescue RubyPi::Error => e
  logger.error("RubyPi error: #{e.message}")
end