[IMP] web_editor: reduce the timeout for chatgpt calls
The timeout for calls to the OLG API in the editor was set to 300 seconds, which is far too long for a chatbot. This reduces it to 30s. closes odoo/odoo#141135 Signed-off-by: Nicolas Bayet (nby) <nby@odoo.com>
This commit is contained in:
@@ -774,7 +774,7 @@ class Web_Editor(http.Controller):
|
||||
'prompt': prompt,
|
||||
'conversation_history': conversation_history or [],
|
||||
'version': release.version,
|
||||
}, timeout=300)
|
||||
}, timeout=30)
|
||||
if response['status'] == 'success':
|
||||
return response['content']
|
||||
elif response['status'] == 'error_prompt_too_long':
|
||||
|
||||
Reference in New Issue
Block a user