code: def _validated(self, value):
          
          if value is None:
              return None
          try:
              return self._format_num(value)
          except (TypeError, ValueError):
              self.fail('invalid', input=value)
          except OverflowError:
              self.fail('too_large', input=value)
docs: Format the value or raise a :exc:`ValidationError` if an error occurs.