{"push_id":810623130,"size":2,"distinct_size":2,"ref":"refs/heads/master","head":"03d7236430348fa4a4ea8b251861796765c70d2f","before":"00dc6d8738a66bceae9d719143c86e490465fe12","commits":[{"sha":"cf6d2ddaf6cabc008c5e2303361b6106c81aa92d","author":{"email":"f10fd5ac6ccbea836dffbca05fac8c20b2cd8189@gmail.com","name":"Doug Hammond"},"message":"Refactor and extend coercion and type validation\n\nAddresses #1164, #690, #689, #693.\n\n`Grape::ParameterTypes` is renamed `Grape::Validations::Types`\nto reflect that it should probably be bundled with an eventual\n`grape-validations` gem. It is expanded to include two new\ncategories of types, 'special' and 'recognized' (see\n'lib/grape/validations/types.rb'). `CoerceValidator` now makes\nuse of `Virtus::Attribute::value_coerced?`, simplifying its\ninternals.\n\n`CustomTypeCoercer` is introduced, attempting to standardize\nsupport for custom types by decoupling coercion and type-checking\nlogic from the `type` class supplied to\n`Grape::Dsl::Parameters::requires`. The process for inferring\nwhich logic to use for each type and coercion method is encoded\nin `lib/grape/validations/types/build_coercer.rb`.\n\n`JSON`, `Array[JSON]` and `Rack::Multipart::UploadedFile (a.k.a\n`File`) are designated 'special' types, for which special\nimplementations of `Virtus::Attribute` are provided.\n\nInstances of `Virtus::Attribute` built with `Virtus::Attribute.build`\nmay now also be passed as the `type` parameter for `requires`.\n\nDepends on a monkey patch to `Virtus::Attribute::Collection`, included\nin `lib/grape/validations/types/virtus_collection_patch.rb`. See pull\nrequest 343 on solnic/virtus for more details.","distinct":true,"url":"https://api.github.com/repos/dslh/grape/commits/cf6d2ddaf6cabc008c5e2303361b6106c81aa92d"},{"sha":"03d7236430348fa4a4ea8b251861796765c70d2f","author":{"email":"ec9fc1d16dbffc59948f4d863a418ee827e4a580@dblock.org","name":"Daniel Doubrovkine (dB.) @dblockdotorg"},"message":"Merge pull request #1167 from dslh/validation_types\n\nRefactor and extend coercion and type validation","distinct":true,"url":"https://api.github.com/repos/dslh/grape/commits/03d7236430348fa4a4ea8b251861796765c70d2f"}]}