fix getting args.root, ask feedback only on success and keyboard interrupt (not on exceptions), fix terminal width and erasing old logs

This commit is contained in:
LeonOstrez
2023-09-29 13:31:11 +01:00
parent 9a2cd09b8b
commit 4c1fe834a8
5 changed files with 18 additions and 8 deletions

View File

@@ -42,10 +42,12 @@ def get_path_id():
return hashlib.sha256(installation_directory.encode()).hexdigest()
def exit_gpt_pilot():
def exit_gpt_pilot(ask_feedback=True):
path_id = get_path_id()
send_telemetry(path_id)
feedback = get_user_feedback()
feedback = None
if ask_feedback:
feedback = get_user_feedback()
if feedback: # only send if user provided feedback
send_feedback(feedback, path_id)