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

Update README/docs to use pyproject.toml + separate setup.py docs #356

Merged
merged 10 commits into from
Aug 24, 2023

Conversation

abravalheri
Copy link
Contributor

@abravalheri abravalheri commented Aug 20, 2023

This PR attempts to target a few review comment in #348, specifically:

We should also update documentation to cover (recommend?) this layout. Again, I'd be tempted to move the documentation of using setup.py to a secondary page in the docs and make this pyproject.toml form the preferred option.

Remarks:

  • For the docs in the README.md I cannot use MyST-specific blocks (like literalinclude) or sphinx directives (like {pep}), because GitHub does not support it. So I just added a simplified version of the hello-world example, and linked where the users could obtain the .rs and .py files.
  • I modified the hello-world-setuppy file to make it simpler and suitable for the separated docs for setup.py. The other examples already cover binaries, so I though that a shared library as Python module would be more relevant.
  • I added a new docs session to nox to facilitate checking how the docs would be rendered.

@abravalheri abravalheri marked this pull request as ready for review August 20, 2023 19:42
Copy link
Member

@davidhewitt davidhewitt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you so much again, this is brilliant!

I was going to suggest we pause on merging this one until setuptools' pyproject.toml support is out of beta, and then I saw you already did that last week ❤️

Just a few tiny suggestions to the prose...

README.md Outdated Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
docs/setuppy_tutorial.md Outdated Show resolved Hide resolved
abravalheri and others added 2 commits August 24, 2023 15:31
Co-authored-by: David Hewitt <1939362+davidhewitt@users.noreply.github.com>
to distribute. You can see examples for these files in the
[`examples/hello-world`](https://github.com/PyO3/setuptools-rust/tree/main/examples/hello-world)
directory in the [github repository](https://github.com/PyO3/setuptools-rust).
The [PyO3 docs](https://pyo3.rs) have detailed information on how to write Python
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we also mention rust-cpython here? Although I don't think there is any example using rust-cpython (or is there?)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's fine as-is; rust-cpython is relatively unmaintained recently and as you say we also lack any example of it here. I think if someone wanted to contribute an example and extend documentation to discuss rust-cpython I would accept it, just no need to block this PR on it.

Copy link
Member

@davidhewitt davidhewitt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks once again, setuptools-rust has enjoyed a great polishing recently by your efforts ❤️

@davidhewitt davidhewitt merged commit 0dc494e into PyO3:main Aug 24, 2023
47 checks passed
@abravalheri abravalheri deleted the update-tutorials branch August 24, 2023 23: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.

None yet

2 participants