From 7632309df7d112dc065df588c966fece242cb20d Mon Sep 17 00:00:00 2001 From: Sanghun Lee Date: Sun, 29 Oct 2023 14:31:35 +0900 Subject: [PATCH 1/2] fix: follow-up updated session template create API --- src/ai/backend/manager/api/session_template.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ai/backend/manager/api/session_template.py b/src/ai/backend/manager/api/session_template.py index 9294c49f69..93c319567f 100644 --- a/src/ai/backend/manager/api/session_template.py +++ b/src/ai/backend/manager/api/session_template.py @@ -269,7 +269,7 @@ async def put(request: web.Request, params: Any) -> web.Response: body = yaml.safe_load(params["payload"]) except (yaml.YAMLError, yaml.MarkedYAMLError): raise InvalidAPIParameters("Malformed payload") - for st in body["session_templates"]: + for st in body: template_data = check_task_template(st["template"]) name = st["name"] if "name" in st else template_data["metadata"]["name"] if "group_id" in st: From cc51bfaf28b98e69f62569be7831d21fc326f907 Mon Sep 17 00:00:00 2001 From: Sanghun Lee Date: Sun, 29 Oct 2023 14:35:47 +0900 Subject: [PATCH 2/2] add news fragment --- changes/1668.fix.md | 1 + 1 file changed, 1 insertion(+) create mode 100644 changes/1668.fix.md diff --git a/changes/1668.fix.md b/changes/1668.fix.md new file mode 100644 index 0000000000..744f014590 --- /dev/null +++ b/changes/1668.fix.md @@ -0,0 +1 @@ +Update the parameter of session-template update API to follow-up change of session-template create API.