From 5635426776373243161e57b31e3a84d20fb4f1e0 Mon Sep 17 00:00:00 2001 From: Ace Nassri Date: Mon, 27 Aug 2018 14:06:57 -0700 Subject: [PATCH] Update main.py --- functions/helloworld/main.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/functions/helloworld/main.py b/functions/helloworld/main.py index f2377eb06005..81eec93b628c 100644 --- a/functions/helloworld/main.py +++ b/functions/helloworld/main.py @@ -149,6 +149,13 @@ def hello_method(request): def hello_error_1(request): # [START functions_helloworld_error] + # This WILL NOT be reported to Stackdriver Error + # Reporting, and WILL NOT show up in logs + try: + raise RuntimeError('I failed you') + except: + pass + # This WILL be reported to Stackdriver Error Reporting, # and WILL terminate the function raise RuntimeError('I failed you')