Logan Hunt
Logan Hunt
Didn't mean to close this
@jdevera I think the reason Refurb is running so slow is because it is using Mypy's fine grained cache, which, from what I can tell, does not get stored/retrieved from...
I think that we could do something like this. There is a tool you might find interesting called [perflint](https://github.com/tonybaloney/perflint), which does (somewhat similar) optimization checks, but none of the specific...
I think that `chain` and `chain.from_iterable` are good candidates, though `groupby` might be a hard use case to detect. Unless there is a common pattern where you find `groupby` is...
I think this is a perfectly valid question! I hope to add a more complete comparison to the README file at some point, but in short: [Black](https://github.com/psf/black) is more focused...
Thank you for the input @chapmanjacobd . Some things I will mention: * The `with suppress(...)` check is indeed a style choice, but the error message saying `except: pass` is...
@pums974 , quoting myself from the [Hackernews article](https://news.ycombinator.com/item?id=33004797) about Refurb: > From looking at the README, Refurb is more focused on simplifying the codebases, making them more expressive, whereas pyupgrade...
If you want to get really fancy, here's another option: ```python with contextlib.suppress(OSError): for line in Path(CMAKE_BUILD_DIR() / "CMakeCache.txt").read_text("utf8").splitlines(): if line.startswith(variable_name): return line.split("=", 1)[-1].strip() ``` Also, I don't like that...
This is on my todo list, and something that I hope to play around with by the end of next week. I'll make sure to report back here on any...
Looks like there is a long road ahead for mypyc: ``` $ mypyc refurb/checks/pathlib/with_suffix.py refurb/checks/pathlib/with_suffix.py:42: error: Match statements are not yet supported ``` There is currently an open issue in...