From a780ae5fc98c44c3dc78f8a91dd341f6fb69f4ae Mon Sep 17 00:00:00 2001 From: Khalim Conn-Kowlessar Date: Mon, 4 Sep 2023 18:33:51 +0100 Subject: [PATCH] json.loads on body to convert from string --- model_data/simulation_system/handlers/predictions_app.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/model_data/simulation_system/handlers/predictions_app.py b/model_data/simulation_system/handlers/predictions_app.py index 1c77897f..c12c3f61 100644 --- a/model_data/simulation_system/handlers/predictions_app.py +++ b/model_data/simulation_system/handlers/predictions_app.py @@ -1,3 +1,4 @@ +import json import os import logging @@ -19,7 +20,7 @@ def handler(event, context): # Assuming a file in a bucket landing for now? # Assuming we have a model to use - body = event["body"] + body = json.loads(event["body"]) data_path = body["file_location"] property_id = body["property_id"]