PyWavelets / pywt

PyWavelets - Wavelet Transforms in Python
http://pywavelets.readthedocs.org
MIT License
1.97k stars 460 forks source link

Add linter #687

Closed jarrodmillman closed 3 months ago

jarrodmillman commented 9 months ago

Not sure folks are interested in this, but pre-commit has been pretty helpful for the other projects I work on. This does introduce some linting noise, but it is ignored by git and GitHub. I am happy to close this or modify it as folks see fit.

If you don't want to add this via pre-commit, I could make a separate PR that just updates the source files with pyupgrade and flynt to remove a ton of older Python cruft.

Thoughts?

rgommers commented 9 months ago

This seems like a useful set of changes to me. And I'm fine with adding the pre-commit yaml file. It doesn't seem to be triggering bot PRs, and the selected linter option seem okay (adding too many is a problem for usability, the ones here are okay with me).

I'll merge this soon unless there are any concerns. I haven't reviewed the full diff yet, but I assume they're all valid changes since they-re tool generated.

jarrodmillman commented 9 months ago

Just a reminder: This will need to be merged with a "Create a merge commit" for the .git-blame-ignore-revs commits to be valid.

rgommers commented 9 months ago

Would you mind fixing the merge conflicts?

jarrodmillman commented 9 months ago

@rgommers This should be ready to go. Is there anything else I can do to help with the next release?

jarrodmillman commented 9 months ago

@rgommers We decided to make pywavelets an optional dependency of scikit-image so we could get 3.12 wheels out: https://pypi.org/project/scikit-image/0.22.0rc1/

But it would still be nice to get 3.12 wheels for pywt out soon. Let me know if I can help. I am happy to do release management for the next release if it would be helpful.

jarrodmillman commented 8 months ago

@rgommers Any updates on this or a new release? I am happy to handle the release if it would help. Thanks!!

jarrodmillman commented 7 months ago

@rgommers It would be great to get 3.12 binaries out soon. This is the only scikit-image (optional) dependency that doesn't support Python 3.12.

rgommers commented 7 months ago

Apologies for the delay @jarrodmillman . New release is up now. I'll deal with remaining PR reviews that were not needed for 1.5.0, including this one, afterwards (hopefully tomorrow).