mjtamlyn / django-adapters

Constructible, introspectable serializers and forms
BSD 3-Clause "New" or "Revised" License
69 stars 7 forks source link

Prototype validation tree #23

Open mjtamlyn opened 8 years ago

mjtamlyn commented 8 years ago

Create a prototype of the validation tree, allowing similar chaining of validation/cleaning functions similar to what Naval can do (see #21).

MoritzS commented 8 years ago

Here is a list of what should be possible:

It would also be nice to be able to continue the validation as far as possible even if one step failed, e.g. if the username contained special characters, the date of birth should still be checked.

To make all of this possible I think using a DAG (Directed Acyclic Graph) is the way to go, compared to Naval's more naive list of validators.

LilyFoote commented 8 years ago

I think Naval's list of validators can be turned into a DAG without much difficulty, so that might still be a good UI for it.