Skip to content

Releases: python-validators/validators

v0.21.0

27 Mar 09:27
9ae6e8e
Compare
Choose a tag to compare

Breaking ⚠️

  • Drops support for all Python versions below v3.8.
  • Makes API's primary parameter, positional, and the remaining, keyword-only.
  • Keyword-only parameters like max and min, has been renamed to max_val and min_val respectively.
  • domain API now accepts two new keyword-only arguments: rfc_1034: bool = False and rfc_2782: bool = False.
  • extremes.py renamed to _extremes.py and is no longer exposed.
  • truthy was discarded in favour of simple bool() function.
  • ipv4_cidr() and ipv6_cidr() has been dropped in favour of cidr: bool = True and cidr: bool = True keyword-only parameters.
  • email() API now accepts the following keyword-only arguments:
    • simple_host: bool = False,
    • ipv6_address: bool = False,
    • ipv4_address: bool = False,
    • rfc_1034: bool = False and
    • rfc_2782: bool = False.
  • whitelist=None has been removed from email().
  • url() has been refactored, it accepts the following keyword-only arguments:
    • skip_ipv6_addr: bool = False,
    • skip_ipv4_addr: bool = False,
    • may_have_port: bool = True,
    • simple_host: bool = False,
    • rfc_1034: bool = False and
    • rfc_2782: bool = False.
  • public=False keyword argument has been removed from url().
  • Exposes i18n functions directly via __init__.py.
  • @validator decorator catches Exception.

Features

  • Adds hostname validator.

Maintenance

Full Changelog: 0.20.0...0.21.0