def save_last_sync(self, ids, process):
        try:
            spec = {'_id': 'last_sync'}
            document = {'$set': {process: ids}}
            self.db.internal.update(spec, document, upsert=True)
        except Exception as e:
            raise DatabaseException(e)
def _rename_item_names(self, start_index):
    for index, item in enumerate(self._items[start_index:]):
      item.label.set_label(self._get_item_name(index + 1 + start_index))