def dup_primitive_prs(f, g, K):
    prs = [f, g]
    _, h = dup_primitive(dup_prem(f, g, K), K)

    while h:
        prs.append(h)
        f, g = g, h
        _, h = dup_primitive(dup_prem(f, g, K), K)

    return prs
Test that an exception is raised with an invalid menu handle
dataset/ETHPy150Open sympy/sympy/sympy/polys/euclidtools.py/dup_primitive_prs--crossover with--dataset/ETHPy150Open JT5D/Alfred-Popclip-Sublime/Sublime Text 2/Browser Refresh/win/pywinauto/unittests/test_menuwrapper.py/MenuWrapperTests.testInvalidHandle