Mon-Ouie / pry-remote

Connect to Pry remotely
Other
639 stars 81 forks source link

Error: argument must respond to `call' running remote-pry #45

Closed MaxGabriel closed 10 years ago

MaxGabriel commented 10 years ago

I'm trying to run pry on a staging server. After using the browser to hit the endpoint where binding.remote_pry is called, I ssh into the server and run remote-pry, and get this stacktace (really long).


Subsequent attempts to run remote-pry give the following error:

bundle exec pry-remote -r ./config/environment.rb
/usr/lib/ruby/1.9.1/drb/drb.rb:736:in `rescue in block in open': druby://127.0.0.1:9876 - #<Errno::ECONNREFUSED: Connection refused - connect(2)> (DRb::DRbConnError)
    from /usr/lib/ruby/1.9.1/drb/drb.rb:730:in `block in open'
    from /usr/lib/ruby/1.9.1/drb/drb.rb:729:in `each'
    from /usr/lib/ruby/1.9.1/drb/drb.rb:729:in `open'
    from /usr/lib/ruby/1.9.1/drb/drb.rb:1191:in `initialize'
    from /usr/lib/ruby/1.9.1/drb/drb.rb:1171:in `new'
    from /usr/lib/ruby/1.9.1/drb/drb.rb:1171:in `open'
    from /usr/lib/ruby/1.9.1/drb/drb.rb:1087:in `block in method_missing'
    from /usr/lib/ruby/1.9.1/drb/drb.rb:1105:in `with_friend'
    from /usr/lib/ruby/1.9.1/drb/drb.rb:1086:in `method_missing'
    from /var/www/heyzap.com/shared/bundle/ruby/1.9.1/bundler/gems/pry-remote-98be78964d0b/lib/pry-remote.rb:285:in `run'
    from /var/www/heyzap.com/shared/bundle/ruby/1.9.1/bundler/gems/pry-remote-98be78964d0b/bin/pry-remote:4:in `<top (required)>'
    from /var/www/heyzap.com/shared/bundle/ruby/1.9.1/bin/pry-remote:23:in `load'
    from /var/www/heyzap.com/shared/bundle/ruby/1.9.1/bin/pry-remote:23:in `<main>'

I've tried with and without the

Pry.config.input = STDIN
Pry.config.output = STDOUT

that the error recommends trying.

I've tried on the latest release of pry-remote, as well as master. The server is running Ubuntu 12.04.2 with ruby 1.9.3p327, with an nginx/unicorn/rails stack. Everything works fine locally (running on OS X Mavericks, same ruby version, with unicorn/rails).

Any ideas?

MaxGabriel commented 10 years ago

I removed the gem rb-readline from my Gemfile, and now its working. I think I just have to up the unicorn timeout now and I'll be good to go.