Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pyo3 bindings for uap-python #3

Merged
merged 1 commit into from
Oct 5, 2024
Merged

pyo3 bindings for uap-python #3

merged 1 commit into from
Oct 5, 2024

Conversation

masklinn
Copy link
Collaborator

@masklinn masklinn commented Jul 15, 2024

  • can do the entire loading in one shot in pure rust from a python iterable
  • work using rust semantics
  • really just works
  • only requires a pyi for type declarations (?)

TODO

  • add wheels building for pypy
  • add wheels building for graal
  • remove Monterey (macos12) since it's going to get removed anyway
  • add Sequoia (macos 15) moved everything to 13 instead
  • remove sdist? don't see what sense it makes...

masklinn added a commit to masklinn/uap-python that referenced this pull request Jul 15, 2024
masklinn added a commit to masklinn/uap-python that referenced this pull request Jul 15, 2024
@masklinn masklinn force-pushed the pyo3-bindings branch 24 times, most recently from 98399a2 to 45efc61 Compare October 5, 2024 09:30
@masklinn masklinn marked this pull request as ready for review October 5, 2024 10:01
@masklinn masklinn force-pushed the pyo3-bindings branch 2 times, most recently from e97168a to 014173a Compare October 5, 2024 13:24
@masklinn masklinn force-pushed the pyo3-bindings branch 20 times, most recently from 9f0762a to 9bb89c1 Compare October 5, 2024 19:10
Advantages
==========

- Can do the entire loading in one shot in pure rust from a python iterable.
- Work using rust semantics.
- Really just works.
- Only requires a pyi for type declarations (?).

Drawbacks
=========

- Likely slower than cffi for pypy, but unlikely to be slower than the
  slog of pure python.
- Graal don't work in tox (oracle/graalpython#427).
@masklinn masklinn merged commit 72e0f2a into main Oct 5, 2024
44 checks passed
@masklinn masklinn deleted the pyo3-bindings branch October 5, 2024 19:41
masklinn added a commit to masklinn/uap-python that referenced this pull request Oct 8, 2024
masklinn added a commit to masklinn/uap-python that referenced this pull request Oct 8, 2024
masklinn added a commit to masklinn/uap-python that referenced this pull request Oct 8, 2024
masklinn added a commit to ua-parser/uap-python that referenced this pull request Oct 8, 2024
masklinn added a commit to masklinn/uap-python that referenced this pull request Oct 13, 2024
Uses ua-parser/uap-rust#3

- add an optional dependency on `ua-parser-rs` under the `regex` key
- add a regex-based parser

misc:

- update the classifiers
- bump required-python to 3.9 (3.8 is basically EOL)
- update CI to better split up the steps
- fix up the check for binary pyyaml: requirements_dev was removed in
  81da21a, in May 2023, so this
  hasn't been working for 18 months
- fix CLI script to correctly handle optional modules so it can run on
  pypy and graal, add regex, make tracemalloc optional as pypy doesn't
  support it (didn't check graal)
- update tox: remove cpython 3.8, pypy 3.8 and 3.9 from tox (3.8's
  last supporting release was 7.3.11 in May 2023, 3.9's was 7.3.16 in
  April 2024), add graal

Fixes ua-parser#166
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.

1 participant