-
-
Notifications
You must be signed in to change notification settings - Fork 18.7k
Closed
Labels
Code StyleCode style, linting, code_checksCode style, linting, code_checksPerformanceMemory or execution speed performanceMemory or execution speed performance
Description
In #41160 , a new pyupgrade feature did some rewrites likes
- s = "\n".join([_build_option_description(k) for k in keys])
+ s = "\n".join(_build_option_description(k) for k in keys)
However, they then reverted this feature as it was a potential performance regression (asottile/pyupgrade#456).
I think we should revert those changes (though arguably not the entire PR) and add a rule to pandas-dev-flaker about using list comprehensions rather than generators when joining strings
If nobody takes this on earlier, I'll do this on Friday
Metadata
Metadata
Assignees
Labels
Code StyleCode style, linting, code_checksCode style, linting, code_checksPerformanceMemory or execution speed performanceMemory or execution speed performance