From f66584713ce1be31eaca62ad3476c470b0930894 Mon Sep 17 00:00:00 2001 From: psychedelicious <4822129+psychedelicious@users.noreply.github.com> Date: Sat, 10 Aug 2024 17:24:28 +1000 Subject: [PATCH] fix(api): sort OpenAPI schema properties for InvocationOutputMap This makes the schema output deterministic! --- invokeai/app/util/custom_openapi.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/invokeai/app/util/custom_openapi.py b/invokeai/app/util/custom_openapi.py index 50259c12cc..e52028d772 100644 --- a/invokeai/app/util/custom_openapi.py +++ b/invokeai/app/util/custom_openapi.py @@ -81,7 +81,7 @@ def get_openapi_func( # Add the output map to the schema openapi_schema["components"]["schemas"]["InvocationOutputMap"] = { "type": "object", - "properties": invocation_output_map_properties, + "properties": dict(sorted(invocation_output_map_properties.items())), "required": invocation_output_map_required, }