diff --git a/functions/executor.js b/functions/executor.js index be5ef10d0..884e29c2b 100644 --- a/functions/executor.js +++ b/functions/executor.js @@ -23,7 +23,7 @@ Deno.serve(async (req) => { status = 200; response = { retval }; } catch (e) { - status = 500; + status = 207; response = { error: toString(e), errorType: typeof e }; } diff --git a/recipes/Functions.py b/recipes/Functions.py index 5987a0235..9175326e3 100644 --- a/recipes/Functions.py +++ b/recipes/Functions.py @@ -71,10 +71,8 @@ def run_v2( raise_for_status(r) data = r.json() response.logs = data.get("logs") - if r.ok: - response.return_value = data.get("retval") - else: - response.error = data.get("error") + response.return_value = data.get("retval") + response.error = data.get("error") def render_form_v2(self): st.text_area(