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

Modernize Python tooling #36

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Conversation

0xDEC0DE
Copy link
Contributor

Move all configs into pyproject.toml, switch test/packaging to use Hatch, and do all the linting with Ruff.

Fix issues that Ruff turned up, and annotate/ignore the pieces that it got wrong.

Fixes: Issue #33

@0xDEC0DE 0xDEC0DE marked this pull request as draft February 28, 2024 19:01
@0xDEC0DE 0xDEC0DE marked this pull request as ready for review February 28, 2024 19:14
spinach/brokers/base.py Outdated Show resolved Hide resolved
spinach/worker.py Outdated Show resolved Hide resolved
.github/workflows/python-publish.yml Outdated Show resolved Hide resolved
Copy link
Collaborator

@bigjools bigjools left a comment

Choose a reason for hiding this comment

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

I filed the ticket yesterday so I had something to work on today :(

This change is doing WAY too much all at once; the intention of the ticket was to only replace setup.py with pyproject.toml, and switch the build system to hatchling and setuptools_scm. I specifically did not want to remove tox (yet) nor change linters, the publisher action, or anything like that. (Side note: you have not updated any documentation.)

.github/workflows/python-publish.yml Outdated Show resolved Hide resolved
@0xDEC0DE 0xDEC0DE marked this pull request as draft February 28, 2024 22:36
@0xDEC0DE
Copy link
Contributor Author

I filed the ticket yesterday so I had something to work on today :(

This change is doing WAY too much all at once; the intention of the ticket was to only replace setup.py with pyproject.toml, and switch the build system to hatchling and setuptools_scm. I specifically did not want to remove tox (yet) nor change linters, the publisher action, or anything like that. (Side note: you have not updated any documentation.)

It's not really that much change, it just looks like it.

The twine publisher method should still work, and that piece is a separate commit, so it can be dropped and handled later.

Most of what looks like churn is simply copy+paste of discrete config files into the corresponding pyproject.toml section. It really does do it all!

The linter changes are similarly low-effort; my original approach was to drop in Ruff with a giant stack of ignores, and promise to peel them back later. I can do that instead, if it makes things easier.

@0xDEC0DE
Copy link
Contributor Author

Downsized for the sake of sanity.

@0xDEC0DE 0xDEC0DE marked this pull request as ready for review February 29, 2024 01:04
nisimond added 2 commits June 2, 2024 18:26
Move all configs into `pyproject.toml`, switch test/packaging to
use Hatch, and do all the linting with Ruff.

Fix issues that Ruff turned up, and annotate/ignore the pieces that
it got wrong.

Fixes: Issue NicolasLM#33
Generate the documentation with `hatch run docs:build $TYPE`
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.

3 participants