On 16Feb2023 04:20, Chris Angelico <ros...@gmail.com> wrote:
On Thu, 16 Feb 2023 at 04:18, scruel tao <scru...@hotmail.com> wrote:
Currently, we have following PEP:
PEP 8: E114 indentation is not a multiple of 4 (comment)

However, I wonder how many people are using 2 spaces as their code indentation 
in projects? Should it be nesserary for us to change this PEP from “multiple of 
4” to “multiple of 2”?

Read PEP 8 itself before making a decision.

1) It is NOT rules for all Python code, only the standard library.
2) 
https://peps.python.org/pep-0008/#a-foolish-consistency-is-the-hobgoblin-of-little-minds

It is not necessary to change the PEP; it is necessary to fix tools
that claim more authority than they actually have.

Speaking as a 2-space indenter myself (in my personal code):

The tool in question is likely `pycodestyle`, whose _default_ linting measures PEP8 criteria among other things.

I run a few different linters (via a script named "lint") and turn off quite a few of the `pycodestyle` checks, `E114` included.

`pycodestyle` doesn't clean any special "authority", and exlicitly offers ways to turn off whichever checks you find unsuitable to your code.

Cheers,
Cameron Simpson <c...@cskk.id.au>
--
https://mail.python.org/mailman/listinfo/python-list

Reply via email to