3 ms·
Pry does allow that with some caution. You can dip into files from the pry prompt ("edit <methodname>" opens the right file at the start of the method definitio
by vidarh 5y ago
Pry does allow that with some caution. You can dip into files from the pry prompt ("edit <methodname>" opens the right file at the start of the method definition) to add methods and reload a class ("reload-code" or "reload-method"), and if you want to you can relatively easily rig things up so you're thrown into a pry prompt on method missing, implement the missing method, and reload the relevant file and retry the call.
Though I'll usually have a "boot" file that loads all pre-requisites and just call functionality from a pry prompt and edit/reload as needed rather than try to continue from a method missing or exception.