From 82cf9d2cfd682cff4de2dc7ff646bdb5b1787364 Mon Sep 17 00:00:00 2001 From: Senko Rasic Date: Tue, 14 Nov 2023 21:08:55 +0100 Subject: [PATCH] don't ask for feedback; also, figure out success/failure --- pilot/main.py | 2 ++ pilot/utils/exit.py | 11 +++++------ 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/pilot/main.py b/pilot/main.py index e51b1a0c31..1e8d92852c 100644 --- a/pilot/main.py +++ b/pilot/main.py @@ -79,11 +79,13 @@ if __name__ == "__main__": project = Project(args, ipc_client_instance=ipc_client_instance) project.start() project.finish() + telemetry.set("end_result", "success") except Exception: print(color_red('---------- GPT PILOT EXITING WITH ERROR ----------')) traceback.print_exc() print(color_red('--------------------------------------------------')) ask_feedback = False + telemetry.set("end_result", "failure") finally: if run_exit_fn: exit_gpt_pilot(project, ask_feedback) diff --git a/pilot/utils/exit.py b/pilot/utils/exit.py index 993e24c02c..b6d259ac9d 100644 --- a/pilot/utils/exit.py +++ b/pilot/utils/exit.py @@ -101,13 +101,12 @@ def exit_gpt_pilot(project, ask_feedback=True): ask_to_store_prompt(project, path_id) - # Ask user for contact email. If they choose not to provide it, ask for direct - # feedback. Both are optional. - if not ask_user_email(project, path_id, ask_feedback): - ask_user_feedback(project, path_id, ask_feedback) + ask_user_email(project, path_id, ask_feedback) + + # TODO: Turned off for now because we're asking for email, and we don't want to + # annoy people. + # ask_user_feedback(project, path_id, ask_feedback) - # We can figure out if we're done, but can't distinguish between crash and interrupted, yet - telemetry.set("end_result", "success" if (project is not None and project.finished) else None) telemetry.set("num_commands", project.command_runs_count if project is not None else 0) telemetry.set("num_inputs", project.user_inputs_count if project is not None else 0)