def synchronize_objects(old_obj, new_obj):
    for key in old_obj.__dict__:
        if key != 'id' and key != '_state' and key not in old_obj.cannot_update and new_obj.__dict__[key]:
            old_obj.__dict__[key] = new_obj.__dict__[key]
    return old_obj
Synchronizes attributes values of two objects
dataset/ETHPy150Open dgraziotin/dycapo/server/utils.py/synchronize_objects