diff --git a/mindinsight/lineagemgr/common/validator/validate.py b/mindinsight/lineagemgr/common/validator/validate.py index 44209b22b81200890d8155105040247533594fc5..8883a2ce29eeb7225c21f9d72e04d34bb5827101 100644 --- a/mindinsight/lineagemgr/common/validator/validate.py +++ b/mindinsight/lineagemgr/common/validator/validate.py @@ -412,7 +412,7 @@ def validate_user_defined_info(user_defined_info): if not isinstance(user_defined_info, dict): log.error("Invalid user defined info. It should be a dict.") raise LineageParamTypeError("Invalid user defined info. It should be dict.") - for key, value in user_defined_info: + for key, value in user_defined_info.items(): if not isinstance(key, str): error_msg = "Dict key type {} is not supported in user defined info." \ "Only str is permitted now.".format(type(key)) diff --git a/mindinsight/ui/src/views/train-manage/image.vue b/mindinsight/ui/src/views/train-manage/image.vue index 402955ce11ab02a9d7b0bf5e66e49143215373d7..7ee274448dec0c8010905bfa7a4fa6b3b230f21b 100644 --- a/mindinsight/ui/src/views/train-manage/image.vue +++ b/mindinsight/ui/src/views/train-manage/image.vue @@ -498,8 +498,8 @@ export default { for (let i = oldTagListLength - 1; i >= 0; i--) { if (!newTagDictionaries[this.tagOperateList[i].label]) { dataRemoveFlag = true; - this.tagOperateList.splice(i, 1); delete this.oriDataDictionaries[this.tagOperateList[i].label]; + this.tagOperateList.splice(i, 1); } } // Delete the old data from the image list and update the dictionary