How to catch all internal exceptions of the framework RoR?

Is there any way to catch only those internal exceptions, which are used by the framework RoR, but not in other frameworks? For example, ActionController::RoutingError, and many others. Maybe they have a common ancestor?
July 8th 19 at 11:40
1 answer
July 8th 19 at 11:42
About ancestors using the ancestors method it is possible to suggest that specifically ActionController::RoutingError base rails class ActionController::ActionControllerError (which already dates back to rubislaw StandardError).

2.3.1 :029 > ActionController::RoutingError.ancestors
 => [ActionController::RoutingError, 
ActionController::ActionControllerError, 
StandardError, Exception, ActiveSupport::Dependencies::Blamable, 
Object, PP::ObjectMixin, ActiveSupport::Dependencies::Loadable, 
V8::Conversion::Object, 
JSON::Ext::Generator::GeneratorMethods::Object, 
Kernel, 
BasicObject]


But I am sure that the other components of Rails has its own parent exception classes, and maybe not even one. For example, there are ActiveRecord ActiveRecord::ActiveRecordError.
You may have to go through the rails source code and look for classes that are inherited from StandardError.

Find more questions by tags ExceptionsRuby on Rails