astral-sh / ruff

An extremely fast Python linter and code formatter, written in Rust.
https://docs.astral.sh/ruff
MIT License
32.31k stars 1.08k forks source link

Support `flake8-class-attributes-order` #2425

Open edgarrmondragon opened 1 year ago

edgarrmondragon commented 1 year ago

Hello, Is there a plan to support this flake8 extension? https://pypi.org/project/flake8-class-attributes-order/

Originally posted by @WorkHardes in https://github.com/charliermarsh/ruff/issues/106#issuecomment-1347928865

sigma67 commented 11 months ago

Has there been a decision to include this yet? Seems quite a few people would use it

lexygon commented 9 months ago

Any decisions on this? It would be an awesome addition

zanieb commented 7 months ago

This one's hard to implement and can generally be unsafe. We don't have plans to implement it soon. Now that we unsafe fix support it might be more reasonable.

cc @AlexWaygood this kind of thing may be worth considering in categorization.

Related https://github.com/astral-sh/ruff/issues/3946

sigma67 commented 7 months ago

I think auto-fixing isn't even the feature request here - although certainly a nice bonus.

Just having the detection capability would be great.

Does your argument only apply to the fixing part or do you also consider the detection hard to implement?

yury-fedotov commented 5 months ago

+1 to this, would be awesome to have it! I think almost any Python project defines many classes, hence having a consistent order of attributes is critical.

mukul-mpac commented 3 weeks ago

+1, even having the capability to detect inconsistencies without having an auto-fix as such would be great!