Uh oh!
There was an error while loading. Please reload this page.
Make some ruff fixes - #8154
Conversation
dhruvmanila
left a comment
There was a problem hiding this comment.
Looks good. There's just one thing I noticed which is that some places have explicit return None while others implicit return. I think we should adopt one or the other. What do you think?
Those rules cover different situations: implicit returns and unnecessary returns. Sometimes
|
dhruvmanila
commented
Mar 1, 2023
The rules exists, but it depends on the project, the maintainers and the audience through which the choice of rules need to be made. Just because a rule exist, doesn't mean it's a necessary thing to do. This is what I think but it's upto you. If you think it's fine, then ok, but I think consistency matters. |
cclauss
commented
Mar 1, 2023
I think that the rules make sense as they are. For functions that never return a value, it is unnecessary to add an extra line at the end. |
* Make some ruff fixes * Undo manual fix * Undo manual fix * Updates from ruff=0.0.251
Describe your change:
ruff --select=RET501,RET502,RET503,SIM101,SIM102,SIM108,SIM109,SIM110,SIM117,SIM118,SIM201,SIM300,PD002,RUF005 --fix .Checklist:
Fixes: #{$ISSUE_NO}.