I often find myself typing out some code that wouldn't pass flake8, then hitting "format selection" or "organise imports" in VSCode. I am using isort and ruff for this (having briefly used black before ruff).
I think it would be useful to define our configs for these tools on a project level so we can agree the style and avoid unnecessary diff resulting from this going forwards.
I've chosen defaults that I think best match our current prevailing style. If we want to haggle over this, make it brief!
To illustrate, I've ruffened/blackened and isorted pathutil.py as a small example.
Check List
[x] I have read CONTRIBUTING.md and added my name as a Code Contributor.
[x] Contains logically grouped changes (else tidy your branch by rebase).
[x] Does not contain off-topic changes (use other PRs for other changes).
[x] No dependency changes
[x] No tests, changelog, docs needed
[x] If this is a bug fix, PR should be raised against the relevant ?.?.x branch.
I often find myself typing out some code that wouldn't pass flake8, then hitting "format selection" or "organise imports" in VSCode. I am using isort and ruff for this (having briefly used black before ruff).
I think it would be useful to define our configs for these tools on a project level so we can agree the style and avoid unnecessary diff resulting from this going forwards.
I've chosen defaults that I think best match our current prevailing style. If we want to haggle over this, make it brief!
To illustrate, I've ruffened/blackened and isorted
pathutil.py
as a small example.Check List
CONTRIBUTING.md
and added my name as a Code Contributor.?.?.x
branch.