CPK is broken?

6 views
Skip to first unread message

Alexey Kovyrin

unread,
Apr 7, 2008, 3:34:26 PM4/7/08
to Composite Keys for ActiveRecord
Subj?

bash-3.2$ sudo gem install composite_primary_keys
Bulk updating Gem source index for: http://gems.rubyonrails.org/
Successfully installed composite_primary_keys-0.9.92
1 gem installed
Installing ri documentation for composite_primary_keys-0.9.92...
Installing RDoc documentation for composite_primary_keys-0.9.92...
bash-3.2$
bash-3.2$ irb
>> require 'rubygems'
=> false
>> require 'activerecord'
=> true
>> require 'composite_primary_keys'
TypeError: superclass mismatch for class HasManyThroughAssociation
from /opt/local/lib/ruby/gems/1.8/gems/
composite_primary_keys-0.9.92/lib/composite_primary_keys/
associations.rb:365
from /opt/local/lib/ruby/site_ruby/1.8/rubygems/
custom_require.rb:27:in `gem_original_require'
from /opt/local/lib/ruby/site_ruby/1.8/rubygems/
custom_require.rb:27:in `require'
from /opt/local/lib/ruby/gems/1.8/gems/
activesupport-2.0.2.9216/lib/active_support/dependencies.rb:495:in
`require'
from /opt/local/lib/ruby/gems/1.8/gems/
activesupport-2.0.2.9216/lib/active_support/dependencies.rb:342:in
`new_constants_in'
from /opt/local/lib/ruby/gems/1.8/gems/
activesupport-2.0.2.9216/lib/active_support/dependencies.rb:495:in
`require'
from /opt/local/lib/ruby/gems/1.8/gems/
composite_primary_keys-0.9.92/lib/composite_primary_keys.rb:38
from /opt/local/lib/ruby/site_ruby/1.8/rubygems/
custom_require.rb:32:in `gem_original_require'
from /opt/local/lib/ruby/site_ruby/1.8/rubygems/
custom_require.rb:32:in `require'
from /opt/local/lib/ruby/gems/1.8/gems/
activesupport-2.0.2.9216/lib/active_support/dependencies.rb:495:in
`require'
from /opt/local/lib/ruby/gems/1.8/gems/
activesupport-2.0.2.9216/lib/active_support/dependencies.rb:342:in
`new_constants_in'
from /opt/local/lib/ruby/gems/1.8/gems/
activesupport-2.0.2.9216/lib/active_support/dependencies.rb:495:in
`require'
from (irb):3
from /opt/local/lib/ruby/gems/1.8/gems/tzinfo-0.3.8/lib/tzinfo/
timezone_period.rb:91
>>
bash-3.2$ rails --version
Rails 2.0.2

darrin

unread,
Apr 7, 2008, 5:13:21 PM4/7/08
to Composite Keys for ActiveRecord
Looks like it's broken for the edge version you're running. Both
revisions 9110 and 9230 changed the HasManyThroughAssociation
superclass. It's a nonstop battle trying to keep up with AR changes.
It should work with the released version of 2.0.2.
Reply all
Reply to author
Forward
0 new messages