You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fetch Product entries and you will get a coerce error because the list here does not support the Number type.
I was able to fork the code, pull down the code base and run the tests, but I did not see where you were testing the inclusion of all data types. in the vcr cassettes I see that there are two 'livesLeft' types, but both are integer, I'm wondering if one was intended to be a decimal. Point out where/if you would like a failing test and I can write one, and deliver test and fix on a PR. Maybe this is a broader issue and that the Number data type should not always be considered a decimal type across the wire. I don't know enough about the system to presume you know what you want here but happy to make a contribution since this seems pretty broken.
stacktrace:
/Users/jed/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/bundler/gems/contentful.rb-ddd04aa8629c/lib/contentful/field.rb:42:in `coerce': undefined method `new' for nil:NilClass (NoMethodError)
from /Users/jed/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/bundler/gems/contentful.rb-ddd04aa8629c/lib/contentful/entry.rb:23:in `coerce'
from /Users/jed/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/bundler/gems/contentful.rb-ddd04aa8629c/lib/contentful/fields_resource.rb:97:in `block in hydrate_fields'
from /Users/jed/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/bundler/gems/contentful.rb-ddd04aa8629c/lib/contentful/fields_resource.rb:96:in `each'
from /Users/jed/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/bundler/gems/contentful.rb-ddd04aa8629c/lib/contentful/fields_resource.rb:96:in `hydrate_fields'
from /Users/jed/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/bundler/gems/contentful.rb-ddd04aa8629c/lib/contentful/fields_resource.rb:10:in `initialize'
from /Users/jed/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/bundler/gems/contentful.rb-ddd04aa8629c/lib/contentful/resource_builder.rb:77:in `new'
from /Users/jed/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/bundler/gems/contentful.rb-ddd04aa8629c/lib/contentful/resource_builder.rb:77:in `build_item'
from /Users/jed/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/bundler/gems/contentful.rb-ddd04aa8629c/lib/contentful/resource_builder.rb:60:in `block in build_array'
from /Users/jed/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/bundler/gems/contentful.rb-ddd04aa8629c/lib/contentful/resource_builder.rb:59:in `map'
from /Users/jed/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/bundler/gems/contentful.rb-ddd04aa8629c/lib/contentful/resource_builder.rb:59:in `build_array'
from /Users/jed/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/bundler/gems/contentful.rb-ddd04aa8629c/lib/contentful/resource_builder.rb:49:in `run'
from /Users/jed/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/bundler/gems/contentful.rb-ddd04aa8629c/lib/contentful/client.rb:284:in `do_build_resource'
from /Users/jed/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/bundler/gems/contentful.rb-ddd04aa8629c/lib/contentful/client.rb:221:in `get'
from /Users/jed/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/bundler/gems/contentful.rb-ddd04aa8629c/lib/contentful/request.rb:30:in `get'
from /Users/jed/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/bundler/gems/contentful.rb-ddd04aa8629c/lib/contentful/client.rb:158:in `entries'
from script.rb:48:in `search'
from script.rb:57:in `<main>'
The text was updated successfully, but these errors were encountered:
create a new space, use the product catalog bootstraped data model
Validate the price on the product data type is a Decimal Number
with the ruby client bundled from master on this repo,
make a request to
/content_types
and response encodes the price as a Number type:fetch Product entries and you will get a coerce error because the list here does not support the Number type.
I was able to fork the code, pull down the code base and run the tests, but I did not see where you were testing the inclusion of all data types. in the vcr cassettes I see that there are two 'livesLeft' types, but both are integer, I'm wondering if one was intended to be a decimal. Point out where/if you would like a failing test and I can write one, and deliver test and fix on a PR. Maybe this is a broader issue and that the Number data type should not always be considered a decimal type across the wire. I don't know enough about the system to presume you know what you want here but happy to make a contribution since this seems pretty broken.
stacktrace:
The text was updated successfully, but these errors were encountered: