From fd0503b9bd64dc92ada228e15a702bdfdd8663b5 Mon Sep 17 00:00:00 2001 From: Eric Rich Date: Fri, 9 Feb 2024 13:42:16 -0500 Subject: [PATCH] Update server.py It is possible for the cloud event `from_http` method to throw a variety of error messages (which you can't debug because the exception is swallowed by this try/catch or method). This should extend a error to the user on why exactly 'No CloudEvent available' is happening. --- parliament/server.py | 1 + 1 file changed, 1 insertion(+) diff --git a/parliament/server.py b/parliament/server.py index 4b48816..39f5463 100644 --- a/parliament/server.py +++ b/parliament/server.py @@ -31,6 +31,7 @@ def handle_post(): request.get_data()) except Exception: app.logger.warning('No CloudEvent available') + app.logger.exception(traceback.print_exc()) return invoke(func, context) @app.route("/", methods=["GET"])