def report_user_error(exc_info, err_file, advice=None):
    """Report to err_file an error that's not an internal error.

    These don't get a traceback unless -Derror was given.

    :param exc_info: 3-tuple from sys.exc_info()
    :param advice: Extra advice to the user to be printed following the
        exception.
    """
    err_file.write('brz: ERROR: %s\n' % (str(exc_info[1]),))
    if advice:
        err_file.write('%s\n' % advice)
