Skip to content

Commit

Permalink
Mark the email address argument to validate_email as positional-only
Browse files Browse the repository at this point in the history
  • Loading branch information
JoshData committed Oct 19, 2023
1 parent 2a9653b commit 371c120
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ In Development
* Python 3.8+ is now required (support for Python 3.7 was dropped).
* The old `email` field on the returned `ValidatedEmail` object, which in the previous version was superseded by `normalized`, will now raise a deprecation warning if used. See https://stackoverflow.com/q/879173 for strategies to suppress the DeprecationWarning.
* A `__version__` module attribute is added.
* The email address argument to validate_email is now marked as positional-only to better reflect the documented usage using the new Python 3.8 feature.

2.0.0 (April 15, 2023)
----------------------
Expand Down
4 changes: 2 additions & 2 deletions email_validator/validate_email.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@

def validate_email(
email: Union[str, bytes],
# /, # not supported in Python 3.6, 3.7
*,
/, # prior arguments are positional-only
*, # subsequent arguments are keyword-only
allow_smtputf8: Optional[bool] = None,
allow_empty_local: bool = False,
allow_quoted_local: Optional[bool] = None,
Expand Down

0 comments on commit 371c120

Please sign in to comment.