def _merge_env(_env, new_env):
    if new_env is not None:
        ret = copy.copy(_env)
        for k, v in new_env.items():
            if ret in k and hasattr(ret[k], "extend"):
                old = copy.copy(_env[k])
                old.extend(v)
                ret[k] = old
            else:
                ret[k] = v
        return ret
    else:
        return _env
dataset/ETHPy150Open cournape/Bento/bento/private/_yaku/yaku/tools/__init__.py/_merge_env/swapped operands of `in`