This is all pretty well summed by Goodhart's law, btw:
@mildbeard Great question. I think some argue that it's impossible. One thing I've been thinking about is keeping multiple, competing goals in balance, and continually evaluating their efficacy as a whole. e.g. "DRY + easy for new comers + easy to change" instead of only "DRY".
Attempting to measure more artful metrics can be useful too. How fast can a new hire get up-to-speed? How quickly can we fix prod issues? How confident are we that we can deploy with no issues every time?