class Cattri::Error

puts “Something went wrong with Cattri: #{e.message}”
rescue Cattri::Error => e
@example
The backtrace is preserved and may be filtered before raising.
rescue handling at the framework level.
All Cattri-specific errors inherit from this class, allowing unified
Base error class for all exceptions raised by Cattri.

def initialize(msg = nil, backtrace = caller)

Parameters:
  • backtrace (Array) -- optional backtrace (defaults to `caller`)
  • msg (String, nil) -- the error message
def initialize(msg = nil, backtrace = caller)
  super(msg)
  set_backtrace(backtrace)
end