doctest doesn't handle intentional SyntaxError exceptions gracefully,
because it picks up the first line of traceback.format_exception_only()
instead of the last line.  Pick up the last line instead!
1 file changed