Ruff v0.1.0
astral.sh
astral.sh
But. v0.1.0 comes with a breaking change: the old `--output` option is now named `--output-format`, and it was only deprecated 3 weeks ago in version 0.0.291 (https://github.com/astral-sh/ruff/releases/tag/v0.0.291). That's bound to break some CI pipelines, and definitely breaks the python-lsp-ruff language server plugin. If you use the latter, I have a PR at https://github.com/python-lsp/python-lsp-ruff/pull/48 that will get you running again for now.
To be super clear, the Ruff team doesn't owe it to anyone to make the command line stable. This is a little inconvenient, but that's our problem, not theirs. They've made an amazing free tool we can all use. Still, it's something you'll need to know about and deal with.
Edit: “our” as in “us end users”. I’m also just an end user of python-lsp-ruff and not associated with it. I realized on re-reading that it might sound like I’m one of its developers. Nope!
Introducing breaking changes can be a hard decision to make, especially knowing that downstream consumers might disagree and their things might break, but the version numbers let you know that it's still unstable and introduced breaking changes.
[0] https://astral.sh/blog/ruff-v0.1.0#ruffs-versioning-policy
However, it’s something that pretty much all Ruff users to know about. Some projects look at their big x.y.Z number and decide to bump y or x to say “hey, it’s been long enough, let’s call it a new version”. This isn’t one of those cases.
It would be an absolute tragedy if they felt compelled to maintain backwards compatibility for philosophical reasons at this stage, if they felt it constrained the capability or usability of their product.
(of course I should have pinned versions...)
Interesting that Ruff has replaced so many linters, and now going for formatter next. One tool to rule them all!
Extra interesting that Ruff appears to provide more knobs than Black, which will likely be a big plus for those not happy with how opinionated Black is.
https://github.com/astral-sh/ruff/discussions/7310#discussio...
You may have avoided the silly argument about code formatting. But if that tendency lives in your engineers, they will find another nit to pick somewhere else.
In my opinion this is not a problem best solved by technology.
The speed of the tool and its development pace astound me.
If the authors/maintainers are lurking here: know that you're doing an amazing job.
Not sure how good it is.
How do I extend Ruff? Can I extend Ruff? How do I write plugins and linters? It's Rust in Python and I am generally leery of such things. The fact that it's one tool to do all these things makes believe it's because the tool is inflexible so it must be able to do all these things.
I think the philosophy right now is to treat it like Black, but I'm not going to speak for the authors or maintainers, it's just my opinion.
Turns out Ruff went and reimplemented the majority of those I use, from scratch. https://docs.astral.sh/ruff/faq/#how-does-ruff-compare-to-fl...
I will say that seeing from afar Charlie has been hiring some very smart people. Not sure how it will turn out but hopefully something good will come of it.
> In the future, we’ll build and sell services on top of our tools — but the tools themselves will remain free and open-source.
> Our plan is to provide paid services that are better and easier to use than the alternatives by integrating our open-source offerings directly. Our goal is for these services to be as impactful as Ruff itself — but you may choose not to use them. Either way, Ruff will remain free and open-source, just as it is today.
It's there in their announcement post.
https://astral.sh/blog/announcing-astral-the-company-behind-...
What are the paid alternative services they are talking about?
For me, the big win is having a single tool instead of a dozen - like when the last flake8 update happened we had to play plug-in Jenga until everything updated, you have different configuration files for flake8, isort, pyupgrade, pylint, bandit, etc. and inconsistent support for pyproject.toml or ignoring things, etc. None of that is a big problem but it’s nice for it just to be gone entirely.
> An extremely fast Python linter, written in Rust.
Pro-tip to announcement authors: it’s helpful when there’s a one-sentence description of the project at the top of a post/article for newcomers who aren’t familiar with the project.