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
I am using an Array type parameter an run into the following error when writing to the database.
SEQUEL DEPRECATION WARNING: Automatically typecasting a hash or array to string for a string column is deprecated and will be removed in Sequel 4.0. Either typecast the input manually or use the looser_typecasting extension.
.../bundle/ruby/2.1.0/gems/sequel-3.48.0/lib/sequel/database/misc.rb:498:in `typecast_value_string'
.../bundle/ruby/2.1.0/gems/sequel-3.48.0/lib/sequel/database/misc.rb:289:in `typecast_value'
.../bundle/ruby/2.1.0/gems/sequel-3.48.0/lib/sequel/model/base.rb:1988:in `typecast_value'
.../bundle/ruby/2.1.0/gems/sequel-3.48.0/lib/sequel/model/base.rb:1056:in `[]='
.../bundle/ruby/2.1.0/gems/sequel-3.48.0/lib/sequel/model/base.rb:769:in `tags='
.../bundle/ruby/2.1.0/gems/sequel-3.48.0/lib/sequel/model/base.rb:1922:in `block in set_restricted'
.../bundle/ruby/2.1.0/gems/sequel-3.48.0/lib/sequel/model/base.rb:1919:in `each'
.../bundle/ruby/2.1.0/gems/sequel-3.48.0/lib/sequel/model/base.rb:1919:in `set_restricted'
.../bundle/ruby/2.1.0/gems/sequel-3.48.0/lib/sequel/model/base.rb:1414:in `set'
.../bundle/ruby/2.1.0/bundler/gems/rack-push-notification-74486fdea05a/lib/rack/push-notification.rb:37:in `block in <class:PushNotification>'
Sequel::DatabaseError - PG::InvalidTextRepresentation: ERROR: missing dimension value
LINE 1: ...ags", "timezone", "token") VALUES ('nl_NL', 'en', '["iPhone ...
^
More specifically, to resolve a conflict I have updated the dependencies of 'rack-push-notification' and the 'tags' parameter gives me the error. For completeness sake, the action that causes the error looks like this:
put '/devices/:token/?' do
param :languages, Array
param :tags, Array
...
The database column has type 'text[]'.
Even though I smuggled with the dependencies, this looks like a pretty generic thing?
The text was updated successfully, but these errors were encountered:
This is an issue with rack-push-notification. sinatra-param coerces to an Array object as expected, but rack-push-notification doesn't have the Postgres pg_array extensions loaded correctly.
Please open an issue for that project, if one does not currently exist.
I am using an Array type parameter an run into the following error when writing to the database.
More specifically, to resolve a conflict I have updated the dependencies of 'rack-push-notification' and the 'tags' parameter gives me the error. For completeness sake, the action that causes the error looks like this:
The database column has type 'text[]'.
Even though I smuggled with the dependencies, this looks like a pretty generic thing?
The text was updated successfully, but these errors were encountered: