From 5519c5c8e39df0e5258f69ca7367a1e16f8db6d8 Mon Sep 17 00:00:00 2001 From: Giancarlo Romeo Date: Mon, 16 Dec 2024 12:15:11 +0100 Subject: [PATCH 1/2] update state when patching node --- .../simcore_service_webserver/projects/projects_api.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/services/web/server/src/simcore_service_webserver/projects/projects_api.py b/services/web/server/src/simcore_service_webserver/projects/projects_api.py index 472855677b4..f4e42879c10 100644 --- a/services/web/server/src/simcore_service_webserver/projects/projects_api.py +++ b/services/web/server/src/simcore_service_webserver/projects/projects_api.py @@ -1049,7 +1049,13 @@ async def patch_project_node( app, project_id ) - # 5. Notify project node update + # 5. Updates project states for user, if inputs have been changed + if _node_patch_exclude_unset.get("inputs"): + updated_project = await add_project_states_for_user( + user_id=user_id, project=updated_project, is_template=False, app=app + ) + + # 6. Notify project node update await notify_project_node_update(app, updated_project, node_id, errors=None) From 9b8ed1dac7695a51880fbab740234a922532d794 Mon Sep 17 00:00:00 2001 From: Giancarlo Romeo Date: Mon, 16 Dec 2024 12:46:10 +0100 Subject: [PATCH 2/2] use in --- .../src/simcore_service_webserver/projects/projects_api.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/services/web/server/src/simcore_service_webserver/projects/projects_api.py b/services/web/server/src/simcore_service_webserver/projects/projects_api.py index f4e42879c10..4f696cff09b 100644 --- a/services/web/server/src/simcore_service_webserver/projects/projects_api.py +++ b/services/web/server/src/simcore_service_webserver/projects/projects_api.py @@ -1050,7 +1050,7 @@ async def patch_project_node( ) # 5. Updates project states for user, if inputs have been changed - if _node_patch_exclude_unset.get("inputs"): + if "inputs" in _node_patch_exclude_unset: updated_project = await add_project_states_for_user( user_id=user_id, project=updated_project, is_template=False, app=app )