Fix error thrown when logging http function invocation

This commit is contained in:
Peter Stockings
2023-12-18 19:39:13 +11:00
parent ca9bf33edf
commit 678e978b4b
2 changed files with 3 additions and 4 deletions

3
app.py
View File

@@ -210,8 +210,7 @@ def execute_http_function(function):
response = requests.post(API_URL, json={'code': code, 'request': request_data, 'environment': environment})
response_data = response.json()
db.update_http_function_environment_info_and_invoked_count(function, json.dumps(response_data['environment']))
db.update_http_function_environment_info_and_invoked_count(function, response_data['environment'])
db.add_http_function_invocation(http_function['id'], response_data['status'], request_data, response_data['result'], response_data['logs'])
# Map the Node.js response to Flask response