

def get_shards_to_update(existing_shards, new_shards):
    assert (len(existing_shards) == len(new_shards))
    shards_to_update = []
    for (existing, new) in zip(existing_shards, new_shards):
        assert (existing_shards.id == new.id)
        if (existing != new):
            shards_to_update.append(new)
    return shards_to_update

dataset/ETHPy150Open dimagi/commcare-hq/corehq/sql_db/config.py get_shards_to_update/VarMisuse@48/74 `existing`->`existing_shards`