Open utterances-bot opened 3 years ago
This is the most readable, understandable and complete Python style guide I've read to date. Thanks for sharing your work!
Under 'Code Layout' you wrote 2 indents betwen classes and 1 indent between methods, but you meant blank lines rather than indents I think.
PEP8 says when calling a function and splitting the arguments onto a new line, indent to match the first line. What do you think of this? Personally I hate it, it's a nuisance to create (because it's not necessarily on a tapstop), and it's a nuisance to maintain if the function name changes.
@hmoffatt you mean like this? That's a lot of work if you do manually with spaces. But since black
can auto-format it, all I did was Ctrl+S...
long_function_name(
first_param,
second_param,
third_param,
very_long_param_name,
another_very_long_param_name,
)
@huydhoang no I meant:
long_function_name(first_param,
second_param,
third_param,
very_long_param_name,
another_very_long_param_name)
@hmoffatt I see, this kind of indentation is totally unnecessary (and ugly).
@hmoffatt, I hate this styling as well :)
The ultimate Python style guidelines - Blog | luminousmen
It is way easier to write the code or do a code review by a strictly defined practical style guide for Python, like PEP8 but better
https://luminousmen.com/post/the-ultimate-python-style-guidelines