don't log entire request on failure

This commit is contained in:
Cyberes 2023-09-26 12:32:19 -06:00
parent b44dda7a3a
commit 0eb901cb52
2 changed files with 0 additions and 3 deletions

View File

@ -65,7 +65,6 @@ def openai_chat_completions():
try:
json_obj = json.loads(json_str.decode())
new = json_obj['text'][0].split(handler.prompt + generated_text)[1]
print(new)
generated_text = generated_text + new
except IndexError:
# ????
@ -111,5 +110,4 @@ def openai_chat_completions():
except Exception as e:
print(f'EXCEPTION on {request.url}!!!', f'{e.__class__.__name__}: {e}')
traceback.print_exc()
print(request.data)
return build_openai_response('', format_sillytavern_err(f'Server encountered exception.', 'error')), 500

View File

@ -19,5 +19,4 @@ def generate():
except Exception as e:
print(f'EXCEPTION on {request.url}!!!', f'{e.__class__.__name__}: {e}')
print(traceback.format_exc())
print(request.data)
return format_sillytavern_err(f'Server encountered exception.', 'error'), 500