Replies: 3 comments 4 replies
-
FYI PEP8 recommends 79 characters per-line. Suggesting the contributors to use an auto-formatter when the repository doesn't fully comply might be complicated since they usually mutate a whole file. If the repository was compliant though, the linter could be enforced during PR pre-flight checks and that would be nice. |
Beta Was this translation helpful? Give feedback.
-
@swamper123 we already have the flake8 stuff in prepository. We jsut need to remove the --exit.-zero and maybe add some config https://github.com/FreeOpcUa/opcua-asyncio/blob/master/.github/workflows/python-package.yml#L36 |
Beta Was this translation helpful? Give feedback.
-
OK. I did some tests and changed my mind. I think the cleaner is use Black without any configuraiton as it is meant to be used. that means 88 char line length. I will probably do it one day and reformat everything unless someone comes with a good argument against. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
maybe use dark or yapf as reference and use flake8.
My only issue is that I hate short lines, so if we do that I will probably remove line length limitation or set it to 160 for example
And then make it clear that yapf/black is adviced before submitting a PR
A related task would be to use black on all existing code. that will be a quite intrusive commit... Not sure it should be done..
https://www.kevinpeters.net/auto-formatters-for-python
Beta Was this translation helpful? Give feedback.
All reactions