Skip to content
This repository has been archived by the owner on Apr 17, 2018. It is now read-only.

Not working for Float property #15

Open
carlosacp opened this issue Nov 27, 2012 · 1 comment
Open

Not working for Float property #15

carlosacp opened this issue Nov 27, 2012 · 1 comment

Comments

@carlosacp
Copy link

I'm receiving strange error when I have Float property in module.

module Comment
  include DataMapper::Resource
  is :remixable
   property :id, Serial
   property :vote, Floar
end

class Post
  include DataMapper::Resource
  ...
  remix 1, :comments
end

the stack trace is

/Users/carlospereira/.rvm/gems/ruby-1.9.2-p320@global/gems/dm-core-1.2.0/lib/dm-core/property.rb:780:in `each': +options[:scale]+ should be Integer, but was NilClass (ArgumentError)
    from /Users/carlospereira/.rvm/gems/ruby-1.9.2-p320@global/gems/dm-core-1.2.0/lib/dm-core/property.rb:780:in `assert_valid_options'
    from /Users/carlospereira/.rvm/gems/ruby-1.9.2-p320@global/gems/dm-core-1.2.0/lib/dm-core/property.rb:743:in `initialize'
    from /Users/carlospereira/.rvm/gems/ruby-1.9.2-p320@global/gems/dm-core-1.2.0/lib/dm-core/property/numeric.rb:16:in `initialize'
    from /Users/carlospereira/.rvm/gems/ruby-1.9.2-p320@global/gems/dm-core-1.2.0/lib/dm-core/model/property.rb:55:in `new'
    from /Users/carlospereira/.rvm/gems/ruby-1.9.2-p320@global/gems/dm-core-1.2.0/lib/dm-core/model/property.rb:55:in `property'
    from /Users/carlospereira/.rvm/gems/ruby-1.9.2-p320@global/gems/dm-validations-1.2.0/lib/dm-validations/auto_validate.rb:11:in `property'
    from /Users/carlospereira/.rvm/gems/ruby-1.9.2-p320@nutri/gems/dm-is-remixable-1.2.0/lib/dm-is-remixable/is/remixable.rb:385:in `block in generate_remixed_model'
    from /Users/carlospereira/.rvm/gems/ruby-1.9.2-p320@global/gems/dm-core-1.2.0/lib/dm-core/support/subject_set.rb:210:in `block in each'
    from /Users/carlospereira/.rvm/gems/ruby-1.9.2-p320@global/gems/dm-core-1.2.0/lib/dm-core/support/ordered_set.rb:319:in `block in each'
    from /Users/carlospereira/.rvm/gems/ruby-1.9.2-p320@global/gems/dm-core-1.2.0/lib/dm-core/support/ordered_set.rb:319:in `each'
    from /Users/carlospereira/.rvm/gems/ruby-1.9.2-p320@global/gems/dm-core-1.2.0/lib/dm-core/support/ordered_set.rb:319:in `each'
    from /Users/carlospereira/.rvm/gems/ruby-1.9.2-p320@global/gems/dm-core-1.2.0/lib/dm-core/support/subject_set.rb:210:in `each'
    from /Users/carlospereira/.rvm/gems/ruby-1.9.2-p320@nutri/gems/dm-is-remixable-1.2.0/lib/dm-is-remixable/is/remixable.rb:384:in `generate_remixed_model'
    from /Users/carlospereira/.rvm/gems/ruby-1.9.2-p320@nutri/gems/dm-is-remixable-1.2.0/lib/dm-is-remixable/is/remixable.rb:188:in `remix'

I'm using DM v 1.2.0

Any idea?

Thank you

@napster3000
Copy link

try "Floar" with "Float" :)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants