docs: def valid_email(x: str) -> bool:
      """
      Return ``True`` if ``x`` is a valid email address; otherwise return
      ``False``.
      """
      if isinstance(x, str) and re.match(EMAIL_PATTERN, x):
          return True
      else:
          return False