Module: RescueRegistry
- Defined in:
- lib/rescue_registry/show_exceptions.rb,
lib/rescue_registry.rb,
lib/rescue_registry/context.rb,
lib/rescue_registry/railtie.rb,
lib/rescue_registry/version.rb,
lib/rescue_registry/registry.rb,
lib/rescue_registry/controller.rb,
lib/rescue_registry/reset_context.rb,
lib/rescue_registry/exceptions_app.rb,
lib/rescue_registry/action_dispatch.rb,
lib/rescue_registry/exception_handler.rb,
lib/rescue_registry/rails_test_helpers.rb,
lib/rescue_registry/action_dispatch/show_exceptions.rb,
lib/rescue_registry/action_dispatch/debug_exceptions.rb,
lib/rescue_registry/action_dispatch/exception_wrapper.rb
Overview
This is for use in non-Rails Rack apps. Rails apps will handle exceptions with ActionDispatch::DebugExceptions and ActionDispatch::ShowExceptions
Defined Under Namespace
Modules: ActionDispatch, Context, Controller, RailsTestHelpers
Classes: ExceptionHandler, ExceptionsApp, HandlerNotFound, RailsExceptionHandler, Railtie, Registry, ResetContext, ShowExceptions
Constant Summary
collapse
- REGISTRY_METHODS =
i[
handler_for_exception
handles_exception?
status_code_for_exception
response_for_debugging
response_for_public
]
- VERSION =
"1.0.0"
Class Method Summary
collapse
Class Method Details
.context ⇒ Object
19
20
21
|
# File 'lib/rescue_registry.rb', line 19
def self.context
Thread.current[:rescue_registry_context]
end
|
.context=(value) ⇒ Object
23
24
25
|
# File 'lib/rescue_registry.rb', line 23
def self.context=(value)
Thread.current[:rescue_registry_context] = value
end
|
.with_context(value) ⇒ Object
27
28
29
30
31
32
33
|
# File 'lib/rescue_registry.rb', line 27
def self.with_context(value)
original = context
self.context = value
yield
ensure
self.context = original
end
|