-
Notifications
You must be signed in to change notification settings - Fork 11
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
Switch to ruff #142
Comments
For context: https://github.com/charliermarsh/ruff |
This has been discussed more extensively on the zulip |
One thing to note is that Ruff is in a (temporary) pickle regarding the new Python parser: astral-sh/ruff#282. In short, no fast libraries seem to exist that can parse the new |
That issue is well on its way, RustPython will merge So there’s nothing keeping us from using ruff! By the time someone will create a new project using this template and add a match statement, support should be complete. |
It would be great to add this one after |
Since @grst suggested using pyupgrade directly instead of the Ruff version, I felt like recapping why using as many checks from Ruff as possible is a good idea:
|
There's either a typo or a misunderstanding. I'm all for using the ruff version of pyupgrade! |
Just to clarify, is there a suggestion here that we'd bundle enabling more checks with switching to ruff? I'd want to stick with just checks and fixes we currently use when using ruff. |
I don't see why we shouldn't add more stuff when we're switching anyways. There's no need to wait for anything here or is there? |
I think we can all agree that some checks are more important than others. Back then in Munich, the argument was to not include less important checks to keep the template less intimidating for new developers. Or do all of the newly suggested checks have autofixes? I'm not sure how that would work for naming conventions for instance. |
+1, definitely want to keep this simple. I also don't think adding ruff should have to bring up new discussions about which checks are good or not. We already spent a lot of time on this, and came up with a big set. Any changes to this set can easily be done separately.
I think ruff has focussed on things with auto fixes, though not all things have auto fixes. In practice, I think this meant prioritizing implementing features from existing tools like isort and autoflake, and de-prioritizing things that just error. I don't think it has many features that haven't been implemented elsewhere (here's what's documented as ruff specific). |
To add to this, I believe the template should be default include the "minimal set of checks that everyone should use" and not "what some some of use want to use". After all, it's very easy to customize the checks after an instance of the repo was created. |
Fair enough :) Agreed. |
I agree! Let’s continue discussion of checks in #149. I think Ruff has a few more checks that fit our selection criteria mentioned there. |
No description provided.
The text was updated successfully, but these errors were encountered: