def METHOD_NAME(df: Table) -> Table:
    """
    For each country we replicate the status as it was in 2017 and then adjust the countries where this status has changed
    """
    df["year"] = df["year"].astype("int")
    years_to_add = [2018, 2019, 2020, 2021, 2022]
    year_to_copy = df[df["year"] == 2017].copy()
    for year in years_to_add:
        year_to_copy["year"] = year
        df = pd.concat([df, year_to_copy], ignore_index=True)
    assert any(df["year"].isin(years_to_add))
    df.loc[(df["country"] == "Angola") & (df["year"] >= 2020), "certification_status"] = "Endemic"
    df.loc[(df["country"] == "Kenya") & (df["year"] >= 2018), "certification_status"] = "Certified disease free"
    df.loc[
        (df["country"] == "Democratic Republic of Congo") & (df["year"] >= 2022), "certification_status"
    ] = "Certified disease free"
    return df