danielgross / whatsapp-gpt

MIT License
3.07k stars 598 forks source link

500 Internal Server Error #90

Open Xf0ur opened 11 months ago

Xf0ur commented 11 months ago

Hello, I was able to run server.py and main.go without a problem, However when someone send me a msg he gets the following response

<!doctype html>

500 Internal Server Error

Internal Server Error

The server encountered an internal error and was unable to complete your request. Either the server is overloaded or there is an error in the application.

Then i see the following errors in server.py [2023-11-01 07:16:23,297] ERROR in app: Exception on /chat [GET] Traceback (most recent call last): File "D:\python-3.12.0\Lib\site-packages\flask\app.py", line 1455, in wsgi_app response = self.full_dispatch_request() ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\python-3.12.0\Lib\site-packages\flask\app.py", line 869, in full_dispatch_request rv = self.handle_user_exception(e) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\python-3.12.0\Lib\site-packages\flask\app.py", line 867, in full_dispatch_request rv = self.dispatch_request() ^^^^^^^^^^^^^^^^^^^^^^^ File "D:\python-3.12.0\Lib\site-packages\flask\app.py", line 852, in dispatch_request return self.ensure_sync(self.view_functions[rule.endpoint])(**view_args) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\whatsapp-gpt-main\server.py", line 61, in chat response = get_last_message() ^^^^^^^^^^^^^^^^^^ File "D:\whatsapp-gpt-main\server.py", line 53, in get_last_message last_element = page_elements[-1] ~~~~~~~~~~~~~^^^^ IndexError: list index out of range Any idea?