Skip to content

v1.3.0

Choose a tag to compare

@derek73 derek73 released this 06 Jul 06:35
b7b728b

This release works through essentially the entire backlog of open issues — nearly every bug and feature request in the tracker, including several dating back to 2014. Alongside the fixes, it adds long-requested functionality: maiden name support, surname-prefix splitting, patronymic name ordering, and a set of new customization hooks on Constants.

The release was developed with Claude Code, and every fix and feature ships with regression tests. The complete list of changes is below.

This release is the bridge release ahead of 2.0: every planned 2.0 removal now has its replacement shipped and emits a DeprecationWarning naming it, so code can migrate while both APIs work. Full details in the release log.

Deprecations (removal in 2.0)

  • == and hash() on HumanName (#223) — the design's three promises (case-insensitive equality, equality with plain strings, hashability) are mutually inconsistent, equality depends on string_format, and maiden is invisible to it. Replacements, new in this release: matches() for semantic comparison (name.matches("Smith, John") and name.matches("John Smith") both match) and comparison_key() for sets, dicts, dedup, and sorting.
  • bytes input (#245) — decode first, e.g. value.decode('utf-8'); the encoding kwarg is deprecated with it.
  • SetManager.__call__ (#243) — iterate the manager or copy with set(manager).
  • SetManager.remove() of a missing member (#243) — will raise KeyError in 2.0 like set.remove; new discard() is the intentional ignore-missing spelling.

Breaking changes

  • HumanName is no longer its own iterator; iter(name) returns a fresh independent iterator (fixes state corruption from break/nested loops/len() mid-loop) (#225)
  • Vestigial unparsable attribute removed (unreachable since 2013; use len(name) == 0); __ne__ removed (derived from __eq__)
  • REGEXES and CAPITALIZATION_EXCEPTIONS are now dicts — iterate with .items() (#227, #233)
  • Internal __process_initial__ renamed _process_initial (dunder names are reserved)

Behavior changes affecting parse output (default-on)

  • Bound Arabic given-name prefixes (abdul, abu, …) join forward into the first name (#150); disable via CONSTANTS.bound_first_names.clear()
  • A leading unknown multi-letter period-abbreviation ("Major.") parses as a title (#109)
  • Parsing no longer mutates the shared CONSTANTS it reads — parse results no longer depend on what was parsed earlier in the process, and parsing is thread-safe against config writes

New

  • maiden field with maiden_delimiters routing (#22); given_names (#157); last_base/last_prefixes for surname particles (#130, #132)
  • patronymic_name_order for Russian and Turkic formal-order names (#85, #185); middle_name_as_last (#133); non_first_name_prefixes (#121); expanded international titles and prefixes (#18, #101, #187)
  • initials_separator (#171), suffix_delimiter (#156), nickname_delimiters (#110, #112), suffix_acronyms_ambiguous (#111)

Hardening & fixes

  • Config boundaries now fail loud instead of silently corrupting: bare strings no longer shred into characters (#238), assignment paths validate (#239, #241), TupleManager rejects malformed input (#242), membership checks normalize like every other operation (#244), Constants subclasses are respected (#226)
  • Customized Constants survive pickle/deepcopy (#167, #168, #169); many parsing fixes — suffix boundaries with prefixed last names (#100), repeated prefix chains (#208), degenerate comma input, roman-numeral and suffix recognition in comma formats (#136, #144), and more