Issue #4 resolved
Ludia
repo owner created an issue

We have a staus field in the transaction engine. It may only be one of "pending", "running", "done". I need a validator to early catch typos.

== Example of bundled validators: ==

  • IN
  • BETWEEN
  • REGEX
  • MIN
  • MAX
  • MINLEN
  • MAXLEN

== Proposed design: ==

  • in schema, 2 definitions options :
    • "field": type
    • "field": {"type": type, "validator": CALLABLE}
  • CALLABLE is only responsible of validations
  • conversions are done according type

OR

  • Replace 'types' in 'schema' by a callable
  • Callable is responsible of DynamoDB -> Python conversion/validation
  • Failure may trigger validation/exception

Comments (6)

  1. Log in to comment