def _assert_single_row(rows_updated):
    if rows_updated == 1:
        return rows_updated
    elif rows_updated > 1:
        raise MultiRowsMatched("%d rows matched; expected one" % rows_updated)
    else:
        raise NoRowsMatched("No rows matched the UPDATE")
dataset/ETHPy150Open openstack/oslo.db/oslo_db/sqlalchemy/update_match.py/_assert_single_row/original