3 ms·
in the python world, i really like Raymond Hettinger’s talk “beyond pep8”, in which he advocates “90-ish” as a line width to shoot for, rather than a slavish fe
by hprotagonist 8y ago
in the python world, i really like Raymond Hettinger’s talk “beyond pep8”, in which he advocates “90-ish” as a line width to shoot for, rather than a slavish fetishism for 80.
This especially matters when you start doing dumb things to codebases like 1-space indents, abbreviated variable names, etc. for the sole purpose of making a linter shut up.
https://m.youtube.com/watch?v=wf-BqAjZb8M https://m.youtube.com/watch?v=wf-BqAjZb8M
- notacoward 8y ago> This especially matters when you start doing dumb things to codebases like 1-space indents Too-small indents are bad for many of the same reasons as too-long lines, only even more so. The main argument in favor seems to be the desire to cram as much as possible into each line, which is a code smell of the first order. The main argument against (which I find much more compelling) is that it becomes really hard to match up the indentation levels to see the true structure of code without artificial aids. Besides being ugly, those faint vertical lines won't be there in every situation, such as when you're looking at code in a review tool or in gdb or a "primitive" editor while you scramble to fix a problem on a production machine that doesn't (and shouldn't) have your favorite heavyweight IDE installed. Ergonomics matters, and it's about more than personal preference.