Spitting the dummy…

Well, I’ve made good progress, but stuck when arriving at p182. Part III: real Rails. Listing 9-2 on the next page has a ‘require_gem…’ at the start of the page and try as I may i can’t get past this. My setup is warning me that this is deprecated and/or not a recognised method. If I remove the line I get  ’uninitialized constant ActiveRecord (NameError) ’ so clearly something is wrong. I thought I’d plough on and see if I could fix it up later but the following examples (i.e. p190, Listing 9-3 require this to build on.So after much tinkering and Googling I’ve drawn a blank and close to spitting the dummy. How many times have I purchased ‘Dummies’ books only to run into road blocks like this. It seems that once a book is published it’s forgotten and almost certain to not have working examples as soon as the code it relies on moves on aversion or two.Not good… It is strangely comforting to see other people falling at the same hurdle…

Monday, June 18th, 2007 Code

2 Comments to Spitting the dummy…

  1. Change the first line of my_ruby_code.rb

    require_gem "activerecord"

    to

    require "active_record"

    This worked for me

    See: http://dev.rubyonrails.org/ticket/8845

  2. Greg on July 29th, 2007
  3. Thanks Greg :-)

  4. David on July 29th, 2007

Leave a comment

Click here for my paper.li page.
Visit Cleartext - Click the Logo

Categories

Sunset on the eventFree fall from 4000mSand boxAuditorium SessionAuditorium SessionAuditorium Session