From d51b336e79a6064d7a490eeec34e4c8fd1877cd9 Mon Sep 17 00:00:00 2001 From: trgiangdo Date: Fri, 3 Nov 2023 18:10:38 +0700 Subject: [PATCH] fix: sort parents list when migrate entities --- src/taipy/core/_entity/_migrate/_utils.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/taipy/core/_entity/_migrate/_utils.py b/src/taipy/core/_entity/_migrate/_utils.py index dcbc1f60..b53165a9 100644 --- a/src/taipy/core/_entity/_migrate/_utils.py +++ b/src/taipy/core/_entity/_migrate/_utils.py @@ -51,6 +51,7 @@ def __search_parent_ids(entity_id: str, data: Dict) -> List: if entity_type == "TASK" and "SCENARIO" in _id: if entity_id in entity_data["tasks"]: parents.append(_id) + parents.sort() return parents @@ -68,6 +69,8 @@ def __search_parent_config(entity_id: str, config: Dict, entity_type: str) -> Li if entity_type == "TASK" and possible_parents == "SCENARIO": if section_id in entity_data["tasks"]: parents.append(section_id) + + parents.sort() return parents