Class: PryRescue
- Inherits:
-
Object
- Object
- PryRescue
- Defined in:
- lib/pry-rescue.rb
Class Method Summary collapse
-
.enter_exception_context(raised) ⇒ Object
Start a Pry session in the context of the exception.
Class Method Details
.enter_exception_context(raised) ⇒ Object
Start a Pry session in the context of the exception.
19 20 21 22 23 24 25 26 27 28 29 |
# File 'lib/pry-rescue.rb', line 19 def enter_exception_context(raised) exception, bindings = raised.last prune_call_stack!(bindings) if defined?(PryStackExplorer) pry :call_stack => bindings, :hooks => pry_hooks(exception, raised) else bindings.first.pry :hooks => pry_hooks(exception, raised) end end |