Undefined method `includes_values' for :conditions:Symbol

Rails 3 / Ruby 1.9.2

Over the weekend I saw the “undefined method `includes_values’
for :conditions:Symbol” error for the 1st time while working with
AAF.

http://j-k.lighthouseapp.com/projects/45560-acts-as-ferret/tickets/176-aaf-051-undefined-method-includes_values-for-conditionssymbol#ticket-176-4

Anyway, i fixed the query and moved on.

Today I hit the error again but I do not have any include queries.
It seems that rails is generating it.

I have a cart that has many cart_items and a cart item belongs to a
domain.

When I try to access the domain in my cart view I get the
‘includes_values’ error on this item (item.domain.id)

<% @cart.cart_items.each{|item| %>

  • Now if I access the domain object in the controller it works fine

    for item in @cart.cart_items
      item.domain.name  #TODO  total hack to avoid undefined method
    

    `includes_values’ for :conditions:Symbol
    end

    Obviously I don’t want to do this but it fixes the problem. Has
    anyone else run into this, usually I figure out my own problem at
    this point but I’m still stumped. :-\

    Thanks in advance for any pointers
    Tony