Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Brew Upgrade Updates Readline Breaking pry #9

Open
payne-chris-r opened this issue Oct 28, 2016 · 12 comments
Open

Brew Upgrade Updates Readline Breaking pry #9

payne-chris-r opened this issue Oct 28, 2016 · 12 comments

Comments

@payne-chris-r
Copy link

Not sure if this is the best place to put this, but Rebekah and I just found that running Brew Upgrade (which she did for Hugo to give her presentation), installed a newer version of lib-readline (7 instead of 6). Because of this change, pry now no longer runs.

Sorry, you can't use byebug without Readline. To solve this, you need to
    rebuild Ruby with Readline support. If using Ubuntu, try `sudo apt-get
    install libreadline-dev` and then reinstall your Ruby.
/usr/local/var/rbenv/versions/2.3.1/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require': dlopen(/usr/local/var/rbenv/versions/2.3.1/lib/ruby/2.3.0/x86_64-darwin15/readline.bundle, 9): Library not loaded: /usr/local/opt/readline/lib/libreadline.6.dylib (LoadError) 
@payne-chris-r
Copy link
Author

Reinstalling ruby also gives build fail errors.

@raq929
Copy link

raq929 commented Oct 28, 2016

@BenGitsCode do you have a fix for this?

@BenGitsCode
Copy link

BenGitsCode commented Oct 28, 2016

@payne-chris-r I believe I do. But it may be slightly different for Rebekah's machine.

In my case I was getting that same error, and installing the rb-readline gem worked as a temporary fix—if you're trying to get up and running with pry and that works, do that as a hot-fix for now.

with mine I got that error, blowing up even more, when I tried to run pry, but eventually noticed pry was working in my bash only terminal. Correcting the pathing in my ~/.zshrc to match the rbenv pathing in my ~/.bashrc turned out to be a better fix than my several attempts and completely wiping and rebuilding ruby.

I can take a look at her steup if this is something you're trying to resolve right now.

@BenGitsCode
Copy link

Also, this may be a pertinent resource https://github.com/rbenv/ruby-build/wiki

@BenGitsCode
Copy link

BenGitsCode commented Oct 28, 2016

I take back everything I said. Pry had zero issues all of last night and yesterday. Today it doesn't work. Rbenv.

@raq929
Copy link

raq929 commented Oct 31, 2016

There's a discussion about this issue here: deivid-rodriguez/byebug#289
Some of the suggestions might be worth trying.

@payne-chris-r
Copy link
Author

We figured it out using this: http://stackoverflow.com/questions/16756287/cannot-execute-rails-console

You need to uninstall ruby and reinstall (build) it now with the new version of readline. The process as I remember it was something like:

rbenv uninstall 2.3.1
rbenv install 2.3.1 && rbenv global 2.3.1

NOTE: You may also need to do the following:

gem install bundler
gem install rubocop
gem install scss_lint

@payne-chris-r
Copy link
Author

@tuckyeah is solving this right now and should have a better list shortly for his exact scenario.

@tuckyeah
Copy link

tuckyeah commented Oct 31, 2016

These are the steps I ran in order:

rbenv uninstall 2.3.1
rbenv install 2.3.1 && rbenv global 2.3.1
gem install rails
gem install bundler
gem install rubocop
gem install scss_lint

These steps did not however install Pry or Byebug (or a few other things), so I went to the most recent challenge which we happened to be working on (https://github.com/ga-wdi-boston/roman-numerals-challenge) and did bundle install

It looks like this challenge included:

rspec
pry
rb-readline
byebug
pry-byebug

So those may need to be installed independently if you don't have a challenge handy to just do a bundle install with. As far as I can tell, everything now seems to be working.... Though I'll update if I run into any further issues.

Also thanks to @rhjones for walking me through this too!!

@gaand
Copy link

gaand commented Oct 31, 2016

@ga-wdi-boston/core rb-readline should not be in any Gemfile.

@BenGitsCode
Copy link

@payne-chris-r I finally fixed this, conclusively, not just the readline hot fix, who's still having the issue. I'll add the fix as an orientation issue and reference it here when I'm at my computer.

@BenGitsCode
Copy link

I ended up again fixing this only temporarily, but I completely nuked and paved nvm and rbenv and redid installfest 016 and haven't had that issue. Was this issue addressed in the last update?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants