Skip to content

Conversation

@masklinn
Copy link
Contributor

@masklinn masklinn commented Jun 9, 2025

Given ua-parser/uap-rust#29 and ua-parser/uap-rust#31, the wording of the comparison needs to be updated to account for:

  • The regex memory use being much improved.
  • The regex runtime on devices being slightly improved, with the Python interface to re2 not supporting custom atom lengths.

Closes #264

Given ua-parser/uap-rust#29 and ua-parser/uap-rust#31, the wording of
the comparison needs to be updated to account for:

- The `regex` memory use being much improved.
- The `regex` runtime on devices being slightly improved, with the
  Python interface to `re2` not supporting custom atom lengths.

Closes ua-parser#264
@masklinn
Copy link
Contributor Author

masklinn commented Jun 9, 2025

Note: needs to wait for the publication of CPython 3.13.5 before being merged (cf ua-parser/uap-rust#37)

@masklinn
Copy link
Contributor Author

masklinn commented Jun 9, 2025

It might actually make sense to remove the re2 feature, and most explicit mentions of that library: the resolver is no burden and is highly valuable to people who would use ua-parser in a codebase where re2 is already available, but if anyone bothers reading the documentation re2 will only provide confusion, regex is strictly more valuable what with being both faster and with better platform supports along all axis (OS, architecture, Python implementation, and CPython version).

Don't remove the feature, don't remove the resolver, and keep the
resolver itself documented, but significantly de-emphasize `re2` by
removing it from the README and from examples: users should not be
encouraged to use it when they could use `regex`.
@masklinn masklinn merged commit 5cd8d51 into ua-parser:master Jun 15, 2025
29 checks passed
@masklinn masklinn deleted the docs branch June 15, 2025 20:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Update resolvers/regex doc section (once a new release of ua-parser-rs has been cut)

1 participant