The logging and diffing changes basically LGTM (see my questions). I paid no attention to other changes (self-test, stencil comparison, python idioms, etc.).
https://codereview.appspot.com/581770043/diff/571840081/scripts/build/output-distance.py File scripts/build/output-distance.py (left): https://codereview.appspot.com/581770043/diff/571840081/scripts/build/output-distance.py#oldcode1074 scripts/build/output-distance.py:1074: print('writing %s' % filename) Before, this would have been printed whether the output was set to verbose or terse. Now, it will only be printed when set to verbose (because open_write_file() logs with log_verbose()). (If that's what you want, OK.) https://codereview.appspot.com/581770043/diff/571840081/scripts/build/output-distance.py File scripts/build/output-distance.py (right): https://codereview.appspot.com/581770043/diff/571840081/scripts/build/output-distance.py#newcode733 scripts/build/output-distance.py:733: log_terse ('creating %s' % outfile) open_write_file() now logs "writing ..." but you changed this to "creating ...". What's the reason for the distinction? https://codereview.appspot.com/581770043/
