We’ve adopted a bunch of code style guidelines over the last couple of years.
According to sipa’s comment:
In my view, writing a particular guideline in the document implies that we’re as a project committing to (eventually) adopting it. Choosing a guideline that mismatches the existing code is giving ourself extra work in fixing it (and while that is ongoing, live with the inconsistencies in the codebase).
The question is whether the suggested style is enough of an improvement over the existing guidelines that it warrants all that work.
We’d eventually like to converge on the new style, but since our developer guidelines state “Do not submit patches solely to modify the style of existing code.”, it’ll be a very long time (or more likely, never) until all code is migrated to the new style.
I’d like to suggest that we take a more proactive approach to change (parts of) the codebase to the new style. This is beneficial because those parts of the codebase can act as models for new contributors, and we could perhaps enable linters on them to enforce style and avoid regressing. We could start with one or two files or modules to migrate.
The obvious time to do this is immediately after a major release: the focus running up to a release branch is on reviewing, so the PR queue is drained, and many of the PRs that are still open will already require rebase. For example, if we decide to do this for the wallet after the 0.18 branch split, there are currently only 18 PRs open that are tagged “Wallet”, not tagged “Needs rebase” and succeeding checks.
Put another way: every line that needs to be changed to converge will be changed eventually, causing rebases for other PRs. Concentrating those changes to times when there are fewest PRs open minimized total rebase pain (although increases it in the short run). There are also economies of scale to just doing a single style rebase over trickling out the changes so there are many small style rebases.
I can see arguments both ways, and would be interested in hearing others’ thoughts.