Hi!
I have problems when a model inherits from another ActiveRecord model:
class Space < ActiveRecord::Base
end
class Project < Space
end
This only happens in development environment. Not in production, neither in
testing. And never in the first request after a server restart, always after
the second request.
So I belive it has to do with something related with class reloading.
It seems like after the reloading, the "Space" part of the Project class is
missing, like in this error (container_posts is a method of Space):
NoMethodError (undefined method `container_posts' for #<Project:0xb4a533cc>):
/usr/lib/ruby/gems/1.8/gems/activerecord-2.1.0/lib/active_record/attribute_methods.rb:256:in
`method_missing'
/vendor/plugins/cmsplugin/app/controllers/posts_controller.rb:18:in
`index'
[...]
I get other errors related with "stack level too deep", but I can't reproduce
them now
_______________________________________________
Engine-Users mailing list
[email protected]
http://lists.rails-engines.org/listinfo.cgi/engine-users-rails-engines.org