def unique_index(df):
    """
    Assert that the index is unique

    Parameters
    ==========
    df : DataFrame

    Returns
    =======
    df : DataFrame
    """
    try:
        assert df.index.is_unique
    except __HOLE__ as e:
        e.args = df.index.get_duplicates()
        raise
    return df
dataset/ETHPy150Open TomAugspurger/engarde/engarde/checks.py/unique_index