rubyamf/rubyamf — Issue #13: Does not work with Rails 3.2 and tests fail
Author: harleyttd
Created: 2012-02-02 01:19:36+00:00
State: open

After upgrading my app to Rails 3.2, I get this error when trying to POST using RubyAMF:

NoMethodError (undefined method `attributes_from_column_definition' for #):

I checked out a copy of rubyamf and run tests on it. Tests pass with Rails 3.1, but when I run with Rails 3.2, any tests that involve spec/model_spec.rb will fail.

This gets spit out repeatedly:

DEPRECATION WARNING: The method `_name', matching the attribute `name' has dispatched through method_missing. This shouldn't happen, because `name' is a column of the table. If this error has happened through normal usage of Active Record (rather than through your own code or external libraries), please report it as a bug. (called from /Users/dtt22/code/gems/rubyamf/spec/model_spec.rb:29)

I haven't been able to figure out what's the root cause, but this refactoring of ActiveRecord may be the culprit:
https://github.com/rails/rails/commit/ceb33f84933639d3b61aac62e5e71fd087ab65ed

Can somebody with advanced knowledge of RubyAMF take a look to see if RubyAMF can be updated to work with ActiveRecord 3.2 please?