MCPcopy Index your code
hub / github.com/tortoise/tortoise-orm / __call__

Method __call__

tortoise/validators.py:59–63  ·  view source on GitHub ↗
(self, value: str)

Source from the content-addressed store, hash-verified

57 self.min_length = min_length
58
59 def __call__(self, value: str) -> None:
60 if value is None:
61 raise ValidationError("Value must not be None")
62 if len(value) < self.min_length:
63 raise ValidationError(f"Length of '{value}' {len(value)} < {self.min_length}")
64
65
66class NumericValidator(Validator):

Callers

nothing calls this directly

Calls 1

ValidationErrorClass · 0.90

Tested by

no test coverage detected