From 0cfbfc1882b052649137859c0e84b4c92cfcde1e Mon Sep 17 00:00:00 2001 From: Artem Goncharov Date: Mon, 22 Apr 2024 15:01:46 +0200 Subject: [PATCH] fix volume.attachments schema by accident list operation was not framed in the "object" container for block-storage volume attachments. Change-Id: I13960a65b4b23cadc10d9547bfdc38c6d6b8d826 --- .../openapi/cinder_schemas/attachment.py | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/codegenerator/openapi/cinder_schemas/attachment.py b/codegenerator/openapi/cinder_schemas/attachment.py index f1011b0..3bd2ef0 100644 --- a/codegenerator/openapi/cinder_schemas/attachment.py +++ b/codegenerator/openapi/cinder_schemas/attachment.py @@ -84,13 +84,23 @@ ATTACHMENT_CONTAINER_SCHEMA: dict[str, Any] = { } ATTACHMENTS_SCHEMA: dict[str, Any] = { - "type": "array", - "items": copy.deepcopy(ATTACHMENT_SCHEMA), + "type": "object", + "properties": { + "attachments": { + "type": "array", + "items": copy.deepcopy(ATTACHMENT_SCHEMA), + } + }, } ATTACHMENTS_DETAIL_SCHEMA: dict[str, Any] = { - "type": "array", - "items": copy.deepcopy(ATTACHMENT_DETAIL_SCHEMA), + "type": "object", + "properties": { + "attachments": { + "type": "array", + "items": copy.deepcopy(ATTACHMENT_DETAIL_SCHEMA), + } + }, }