dosisod / refurb

A tool for refurbishing and modernizing Python codebases
GNU General Public License v3.0
2.48k stars 54 forks source link

Add `no-sorted-min-max` check (FURB192) #333

Closed dosisod closed 5 months ago

dosisod commented 5 months ago

Closes #332.

Skylion007 commented 5 months ago

https://github.com/astral-sh/ruff/issues/10463#issuecomment-2008961107 heads up the [-1] variants may be unstable which matter when sorting tuple. I'd start with the obviously safe example of min and expand it out if we can verify min/max match the stability of 'sorted'.