for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
module Koine
module Attributes
class InvalidAttributeError < ::ArgumentError
attr_reader :attribute_name
def initialize(error, attribute_name)
@attribute_name = attribute_name
if error.is_a?(Exception)
set_backtrace(error.backtrace)
error = error.message
end
error = "#{attribute_name}: #{error}" if attribute_name
super(error)