colander icon indicating copy to clipboard operation
colander copied to clipboard

Add preparer for serialize

Open digitalresistor opened this issue 6 years ago • 0 comments

Currently when you serialize values, there is no preparer step before passing it off to the sub-types (in the case of the MappingSchema)

https://github.com/Pylons/colander/blob/141263a3f61bed7c3af92c3a8d293ca7e10732e8/colander/init.py#L2276-L2293

this means we can not influence the appstruct before passing it off to the various subtypes in the mapping schema

https://github.com/Pylons/colander/blob/master/colander/init.py#L811-L818

This doesn't match the deserialize API which has a preparer function that can be used to modify the cstruct before passing to children and or validation.

digitalresistor avatar Feb 26 '19 06:02 digitalresistor