Change Python code formatter from yapf to Black
During some discussions at Tiger Team meetings I have proposed changing from the yapf auto-formatter to the Black auto-formatter.
Personally, I have used Black in all my other projects and I prefer the alignment/styling, and @timothyfrank.davies and I do have a preference for a slightly longer line length (+10%).
Given auto-formatter selection is primarily subjective and the main developers (us) have a preference for Black over yapf, we would like to push to make this change in the future.
I recommend that after the 4th July review we do a self-contained auto-formatter change where we do an injection test, run the Black auto-formatter, then re-run the injection test, to minimise any problems the reviewers might have with changing a large number of files at once.
Additionally, this is also motivated by some problems where our yapf formatter was not automatically correcting Python2.7 strings formatted with `%` characters that also had line-breaks - running `yapf -i --style pep8 <file>` would run successfully with no suggested alterations (i.e. silently break?) but then our gitlab runner would error when running yapf-diff. The fix was to **manually** add in backslashes after yapf would silently error, which is unacceptable. See [pipeline history](https://git.ligo.org/lscsoft/spiir/-/merge_requests/46/pipelines#587d266bb27a4dc3022bbed44dfa19849df3044c) for !46.
Edit: also see [this broken commit](https://git.ligo.org/lscsoft/spiir/-/commit/015d01989b0ee81a73114c77387892bd153e2871) followed by [this successful commit](https://git.ligo.org/lscsoft/spiir/-/commit/4810180a34dcd5f45069fdec61512345447bc95f) in !47.
issue