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

Fix rustfst-python build in various ways to support Python 3.12 among other things #281

Open
wants to merge 10 commits into
base: main
Choose a base branch
from

Conversation

dhdaines
Copy link
Contributor

@dhdaines dhdaines commented Aug 16, 2024

Fixes: #283

  • Switch to pyproject.toml configuration exclusively
  • Hoist pyproject.toml to top-level directory, necessary in order to...
  • Make a proper source distribution with the Rust files needed to build from source with build isolation
  • Update cibuildwheel to use the github action

@dhdaines
Copy link
Contributor Author

Will fix the Python tests, etc, shortly!

@dhdaines
Copy link
Contributor Author

Seems to be good now! Obviously I can't entirely test the release workflow but I did get it to build all the wheels for Linux/MacOS and the source distribution (something you didn't have before).

@dhdaines
Copy link
Contributor Author

Note also that your pylint configuration was way out of date which is why you had to pin an ancient version of pylint (which does not work with recent versions of Python). I have fixed this and unpinned the versions of everything, because personally I am philosophically opposed to that, but you could of course rerun pip-compile and bring back the requirements files ;-)

@dhdaines
Copy link
Contributor Author

Another note: I kept the cibuildwheel configuration in .github/workflows/native.yml but it could be moved to pyproject.toml as well - this would make it easier to test cibuildwheel by running it locally.

Up-to-date versions of mkdocstrings now are stricter about
dostring syntax and *require* blank lines between sections.
See: https://mkdocstrings.github.io/griffe/reference/docstrings/#google-syntax
@dhdaines
Copy link
Contributor Author

Another note: the docstrings had many problems with more recent versions of mkdocstrings. Namely they need to have blank lines between sections since... a while ago, I guess. So I fixed that too. You could pull it out with commit 2663824 if you aren't ready for the rest of the PR.

See: https://mkdocstrings.github.io/griffe/reference/docstrings/#google-syntax

@dhdaines
Copy link
Contributor Author

Alternately you could revert to the legacy mkdocstrings parser: https://mkdocstrings.github.io/python-legacy/

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.

Python module does not build with Python 3.12
1 participant