[Mongrel] Mongrel/Rails weird problem with methods becoming private

Zed A. Shaw zedshaw at zedshaw.com
Thu Jan 4 21:52:04 EST 2007

On Thu, 4 Jan 2007 18:39:35 +0000
"Paul King" <cronald at gmail.com> wrote:

> Hi,
> I'm new to this list, so apologies if this is a duplicate (or nothing
> to do with mongrel!)
> Somehow when I run my rails app under mongrel, this code:
> > user.interests.include?( interest )
> breaks with the following error:
> > NoMethodError in Profiles#change_interests
> > private method `equal?' called for #<Interest:0xb767ae8c>
> Having spent a fair bit of time testing with the rails console, and
> running the app via webrick (it works in both cases) I can only guess
> I've screwed something up with mongrel.

Generally this happens when you've got something that already defined Interest and then you use it later.  There's nothing in mongrel named Interest or Profiles so it's maybe something else.
> On another box with the same mongrel gem versions, it works fine.  A
> week later I'm asking in desperation, what have I broken?!

If it works in one place, but not in another, then you have to find out what the difference is between the two systems.  I think you've probably got a gem or a version of a gem in one but not the other.  Do a gem list on both and then diff the results.  That'll tell you what's different.

> Either way, a massive thanks for mongrel - it's by far the best
> solution I've found so far to running my app :-)

No problem.  Let me know what you find.

Zed A. Shaw, MUDCRAP-CE Master Black Belt Sifu
http://www.awprofessional.com/title/0321483502 -- The Mongrel Book
http://www.lingr.com/room/3yXhqKbfPy8 -- Come get help.

More information about the Mongrel-users mailing list