You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is probably a big feature request (and apologies if it has already been asked about), but I am wondering whether there are plans for ruff to allow user-defined / config-defied lint rules?
In particular, I have some internal codebase functions that are deprecated and would like people to move off of. I can certainly try to write a custom CI rule for this, but it'd be super nice if I could somehow configure ruff to detect this (since it's already integrated into our CI).
I admit I haven't fully thought through what this would look like in practice. I'd love a world where I can specify in my toml file something like:
[ruff.deprecated]
rule1 = { function="my.code.deprecated_function", message="This function is deprecated", replacement="some.other.function", safe=False}
Is something like this feasible?
(There's a more general question about a plugin interface -- our codebase is big enough that having custom lint rules is useful, but it's not OSS so upstreaming changes to ruff probably isn't worthwhile and forking ruff to add our own rules seems undesirable).
The text was updated successfully, but these errors were encountered:
Hi, thanks for the feature request! My instinct is that we should probably fold this into the broader discussion in #283, which discusses design principles for plugins/user-specific lints.
This is probably a big feature request (and apologies if it has already been asked about), but I am wondering whether there are plans for ruff to allow user-defined / config-defied lint rules?
In particular, I have some internal codebase functions that are deprecated and would like people to move off of. I can certainly try to write a custom CI rule for this, but it'd be super nice if I could somehow configure
ruff
to detect this (since it's already integrated into our CI).I admit I haven't fully thought through what this would look like in practice. I'd love a world where I can specify in my toml file something like:
Is something like this feasible?
(There's a more general question about a plugin interface -- our codebase is big enough that having custom lint rules is useful, but it's not OSS so upstreaming changes to ruff probably isn't worthwhile and forking ruff to add our own rules seems undesirable).
The text was updated successfully, but these errors were encountered: