This project is archived and is in readonly mode.

#2617 ✓stale
Peter Marklund

Global Ruby Methods Causing ActiveRecord Attribute Methods to Never be Defined

Reported by Peter Marklund | May 7th, 2009 @ 02:31 PM | in 3.x

I ran into a clash between RSpec and the acts_as_taggable_on plugin. It turns out that a global method can cause the ActiveRecord attribute methods to never be defined. Since the method already exists method_missing in attribute_methods.rb is never invoked. Instead the global method is invoked.

I have blogged about this issue here:

http://developer.newsdesk.se/200...

I don't have a patch for this, sorry, but it seems we should be able to define the attribute accessors when we load the ActiveRecord model class.

Comments and changes to this ticket

  • Jeremy Kemper

    Jeremy Kemper May 4th, 2010 @ 06:48 PM

    • Milestone changed from 2.x to 3.x
  • Rohit Arondekar

    Rohit Arondekar October 9th, 2010 @ 04:23 AM

    • State changed from “new” to “stale”
    • Importance changed from “” to “”

    Marking ticket as stale. If this is still an issue please leave a comment with suggested changes, creating a patch with tests, rebasing an existing patch or just confirming the issue on a latest release or master/branches.

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>

Pages