Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

pry-nav work unexpectedly

Tags:

ruby

pry

I put binding.pry in my script,

But now when it's stopped at the breakpoint,

is shows me that information.

Which is out of my expectation, how to fix it ?

Frame number: 0/11

From: /Users/me/.rbenv/versions/2.1.2/lib/ruby/gems/2.1.0/gems/pry-nav-0.2.4/lib/pry-nav/tracer.rb @ line 21 PryNav::Tracer#run:

    12: def run(&block)
    13:   # For performance, disable any tracers while in the console.
    14:   # Unfortunately doesn't work in 1.9.2 because of
    15:   # http://redmine.ruby-lang.org/issues/3921. Works fine in 1.8.7 and 1.9.3.
    16:   stop unless RUBY_VERSION == '1.9.2'
    17:
    18:   return_value = nil
    19:   command = catch(:breakout_nav) do      # Coordinates with PryNav::Commands
    20:     return_value = yield
 => 21:     {}    # Nothing thrown == no navigational command
    22:   end
like image 280
user3675188 Avatar asked Nov 11 '14 07:11

user3675188


1 Answers

I had the same issue recently. Check your pry gems by typing the following into the terminal:

gem list pry

This should return all of your pry related gems. I fixed the issue by uninstalling all of the extra pry gems (e.g., pry-nav). The one that was causing the issue for me was the pry bye-bug gem.

like image 58
Karim Avatar answered Sep 29 '22 15:09

Karim