I've reset my system to use 0.9.11 of dm-core, dm-more, data_object,
do_sqlite3, extlib
For this code:
---------- cut ------------
#!/usr/bin/env ruby
require 'rubygems'
require 'dm-core'
DataMapper.setup :default, 'sqlite3::memory:'
class Address
include DataMapper::Resource
property :id, Serial
has 0..n, :people, :through => Resource
end
class Person
include DataMapper::Resource
property :id, Serial
has 0..n, :addresses, :through => Resource
end
DataMapper.auto_migrate!
---------- cut ------------
I'm seeing this error:
/opt/local/lib/ruby/gems/1.8/gems/dm-core-0.9.11/lib/dm-core/
associations/relationship.rb:66:in `parent_model': Cannot find the
parent_model Addres for AddressPerson (NameError)
from /opt/local/lib/ruby/gems/1.8/gems/dm-core-0.9.11/lib/dm-core/
associations/relationship.rb:50:in `parent_key'
Notice that it is looking for a parent model of "Addres", i.e.,
missing an 's'.
I've tried setting the inflector:
Extlib::Inflection.word 'address', 'addresses'
No change.
I've tried specifying the :class_name => 'Address' on the
relationship, no joy.
Any ideas?
TIA,
Roy
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"DataMapper" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/datamapper?hl=en
-~----------~----~----~----~------~----~------~--~---