Pretty straightforward branching on .minimallyEncoding to appease flow. The amount of cut/paste here is very excessive. I'm just trying to get to 0 flow issues first, and then will come back and refactor these as best as possible.
Probably won't land any diffs in this stack until all the flow branching has been tidied up as much as possible.
[skip-ci]
Depends on D10272