Skip to content

Gradual adoption: option to only format PEP8 errors #134

Description

@max-sixty

If I were starting a project from scratch, I'd start with enforcing black. But most code is written on existing projects, and converting everything to black requires a high degree of confidence and share of agreement within contributors.

What do you think about enabling an option in black to reformat only:

  • Code that violates PEP8 / some rules
  • Code that has been changed

One of the nice attributes of autopep8 is that it only changes code where there's a problem. This has two big advantages to adoption:

  • The impact is limited to strict, unambiguous improvements
  • Projects don't require everyone to agree that autopep8 is the correct tool - an individual / subset can start using it for their contributions

Thanks again for the project

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    R: rejectedThis will not be worked onT: styleWhat do we want Blackened code to look like?

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions