HyukjinKwon opened a new pull request #35126: URL: https://github.com/apache/spark/pull/35126
### What changes were proposed in this pull request? This PR proposes to enable flake8 rules as below: - [F841](https://www.flake8rules.com/rules/F841.html): Local variable name is assigned to but never used - [E722](https://www.flake8rules.com/rules/E722.html): Do not use bare except, specify exception instead - [E305](https://www.flake8rules.com/rules/E305.html): Expected 2 blank lines after end of function or class - [E226](https://www.flake8rules.com/rules/E226.html): Missing whitespace around arithmetic operator We should still enable the rules below: - [E731](https://www.flake8rules.com/rules/E731.html): Do not assign a lambda expression, use a def - [E741](https://www.flake8rules.com/rules/E741.html): Do not use variables named 'I', 'O', or 'l' - [W503](https://www.flake8rules.com/rules/W503.html): Line break occurred before a binary operator - [W504](https://www.flake8rules.com/rules/W504.html): Line break occurred after a binary operator These rules are not enabled in this PR because: - There are too many instances to fix. Maybe it's better to separate PRs - Some required code changes. - W503 and W504 are sort of conflicted. We should investigate a bit more. ### Why are the changes needed? To comply PEP 8. ### Does this PR introduce _any_ user-facing change? No, dev-only. ### How was this patch tested? I manually tested it Python linter. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
