News for hackers. Stuff that matters.
Re:Google Python Style Guide by VeejayRampay on Saturday February 11, 2023 @04:24AM (#34750823)
it also doesn't know how to deal with simple constructs like match...case

I agree that ruff seems to be the way forward, it's (almost) at feature-parity, it is extremely fast, but I think it needs polishing

Re:Google Python Style Guide by dharmab on Saturday February 11, 2023 @06:41AM (#34751454)
IIRC this is Ruff's criteria for 1.0
Re:Google Python Style Guide by estebank on Saturday February 11, 2023 @09:27AM (#34752536)
I was gonna ask if match case wasn't a really recent thing, but it seems to be from 3.10 released in October 2021.
Re:Google Python Style Guide by VeejayRampay on Saturday February 11, 2023 @11:11AM (#34753571)
to be honest it is fairly recent and is not exactly "basic", I'm sure ruff people will end up covering it in the near future, I just thought it might bring some balance to mention that it doesn't yet go a hundred percent
Re:Google Python Style Guide by matsemann on Saturday February 11, 2023 @02:00PM (#34755169)
I feel like it have taken quite a few tools some time to catch up. Or if they've caught up, it wasn't straight out of the box. Like, I had to upgrade my linter to handle match cases, but that bump (as we were running an older version) also introduced new rules breaking other code. Since I didn't want to take that work right then, I rewrote to an older if statement and put a task in the backlog to upgrade the linter.

So I've actually seen little use of match cases so far.

Re:Google Python Style Guide by bbkane on Saturday February 11, 2023 @09:57AM (#34752835)
I just tried ruff last night and ran into the match-case support issue. I'm following https://github.com/charliermarsh/ruff/issues/282 and looking forward to trying ruff again once that issue is closed.