The validation of the input data is a very common problem that we face almost every day. The correct and expected input is very important in order to achieve proper and expected execution flow.
Every program receives some kind of input data. It can by anything - from variables, command line options, HTML web forms, and configuration files to binary data. All of this needs to be checked to prevent unexpected errors from happening. Although ActiveModel::Validations is great for web apps and simple models, it isn't very flexible for other types of validation and complex dependencies.