Uh oh!
There was an error while loading. Please reload this page.
Refactor: Consolidate import and usage of random - #34108
Conversation
4f6dcbf to
6ecc955CompareThere was a problem hiding this comment.
Wow this entire function can use a rewrite. (Not saying you should do it in this PR.)
eumiro
commented
Sep 6, 2023
I'm suggesting having all imported modules/classes the same way, so in this case there's always There are cases where I do |
Lee-W
commented
Sep 7, 2023
Yep, agree unifying them would be great 👍 Do we want to document it somewhere? (e.g., use |
potiuk
commented
Sep 7, 2023
I think those kind of rules are rarely read and we have two approaches there that 'work' a) hope that people will follow what is in the code (not perfect but mostly works) - this is a stage we are currently in b) better - add pre-commit to do ast parsing and add rules of things we want do not want to have. I'd say it would be great if thos unification that can be done (imports are generally easy) are added as a rule to pre-commits Maybe you can work with @eumiro together to determine the list of rules that can be automatically verified and and write a pre&commit doing it ? |
(cherry picked from commit 4fa66d1)
No description provided.