def _fix_tups(x):
    if isinstance(x, tuple) and len(x) == 1:
        return x[0]
    return x
Return x[0] if x is a single element tuple, else return x.
dataset/ETHPy150Open OpenMDAO/OpenMDAO-Framework/openmdao.main/src/openmdao/main/driver.py/_fix_tups