def reject_dud(session, dud, tag):
    session.rollback()

    print "REJECT: {source} because {tag}".format(
        tag=tag, source=dud['Source'])

    emit('reject', 'result', {
        "tag": tag,
        "source": dud['Source'],
    })

    for fp in [dud.get_dud_file()] + dud.get_files():
        os.unlink(fp)
    # Note this in the log.
dataset/ETHPy150Open Debian/debile/debile/master/incoming_dud.py/reject_dud/original