Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

Ruby

Jeremy Hertz
Jeremy Hertz
6,095 Points

rails console not working

Whenever I try to use the rails console, I get the following error: http://pastebin.com/5y4hQNUU

I'm using Ruby 2.1.2p95 and Rails 4.1.1

I'd appreciate any help to get rid of the error. Thanks.

2 Answers

Bob Hensley
Bob Hensley
26,421 Points

This looks to be an issue with readline. If you have readline installed, make sure you also have the development package installed. On YUM-based distros this would do it for ya:

yum install readline-devel
Daniel Cardenas
PLUS
Daniel Cardenas
Courses Plus Student 9,236 Points

Same thing happened to me. Here's what worked for me.

I added the following code to my Gemfile:

gem 'protected_attributes'

And then I ran bundle in my terminal: treehouse:~/projects/treebook (master *) $ bundle

After that everything seemed to work.