in the documentation you cited, the following note is in the opening section of the docs.
See also
The third-party regex module, which has an API compatible with the standard library
re
module, but offers additional functionality and a more thorough Unicode support.
Given that Gramps is heavy in Unicode use (and the recent inquiry about Case Sensitivity not being controllable), is that third-party regex more appropriate for Gramps than the standard library re module?