0

This question was asked before here, but can't say that the answer helps me. I am using Rails 3.1.3. When I run rails console on my local dev machine, I get the following message:

no such file to load -- map_by_method

The message doesn't prevent the irb session from launching, so it's benign. But I'd like to get rid of it. At one point in time I had the map_by_method gem installed, but I removed it from the Gemfile and gemset -- yet the message still appears. Any idea how to vanquish it?

Community
  • 1
  • 1
keruilin
  • 16,782
  • 34
  • 108
  • 175
  • 1
    there might be some causes for this: 1. there might be some other gem which has it as a dependency, 2. you might have a require 'map_by_method' in your code 3. you might have a require in your .irbrc – phoet Dec 22 '11 at 17:57
  • how do you modify the .irbrc? – keruilin Dec 23 '11 at 07:41
  • like any other file. have a look at this example http://matthewhutchinson.net/2010/9/19/rails-3-bash-aliases-and-irbrc-configs – phoet Dec 23 '11 at 10:30
  • That was it. Please add your comment as an answer so I can award. – keruilin Dec 29 '11 at 06:56
  • glad it helped. i added it as an answer, you could have also marked my comment as helpful, wich is equaly awarding ;) – phoet Dec 29 '11 at 15:32

2 Answers2

0

Probably the gem map_by_method has done some permanent changes on your system. Try re-installing it. It should fixed your problem. Same thing happened to me once. If it doesn't, try specifying it in development section of gemfile.

0

there might be some causes for this:

  1. there might be some other gem which has it as a dependency
  2. you might have a require 'map_by_method' in your code
  3. you might have a require in your .irbrc

the .irbrc can be located in your user home or in the current working directory. have a look at an example .irbrc here: http://matthewhutchinson.net/2010/9/19/rails-3-bash-aliases-and-irbrc-configs

phoet
  • 18,688
  • 4
  • 46
  • 74