diff --git a/CHANGES.txt b/CHANGES.txt index 02b4949..1908d9e 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -26,6 +26,15 @@ Features - Allow localization of error messages returned by ``colander.Invalid.asdict`` by adding an optional ``translate`` callable argument. +Backwards Incompatibilities +~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +- ``SchemaNode.deserialize`` will now raise an + ``UnboundDeferredError`` if the node has an unbound deferred + validator. Previously, deferred validators were silently ignored. + See https://github.com/Pylons/colander/issues/47 + + 1.0b1 (2013-09-01) ------------------ diff --git a/docs/api.rst b/docs/api.rst index 8f972bd..51b6d75 100644 --- a/docs/api.rst +++ b/docs/api.rst @@ -48,6 +48,9 @@ Exceptions from a widget as the value which should be redisplayed when an error is shown. + .. autoclass:: UnboundDeferredError + + Validators ~~~~~~~~~~ diff --git a/docs/binding.rst b/docs/binding.rst index 61e5efa..94340c2 100644 --- a/docs/binding.rst +++ b/docs/binding.rst @@ -248,7 +248,8 @@ If you use a schema with deferred ``validator``, ``missing`` or ``default`` attributes, but you use it to perform serialization and deserialization without calling its ``bind`` method: -- If ``validator`` is deferred, no validation will be performed. +- If ``validator`` is deferred, :meth:`~colander.SchemaNode.deserialize` will + raise an :exc:`~colander.UnboundDeferredError`. - If ``missing`` is deferred, the field will be considered *required*.