Open Plugless opened 3 years ago
我的也是,请问老哥解决了吗
解决了,把main.py里的try except都注释了。
解决了,把main.py里的try except都注释了。 好的,感谢
解决了,把main.py里的try except都注释了。
不行欸,还是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.
请问解决了吗
请问解决了吗
没有
把main.py里search()函数的print(time.clock())注释掉试试看
有用 感谢!
代码完全没动,新闻也没有更新,直接运行main.py后,可正常访问 http://127.0.0.1:5000/,但是进行搜索就会跳转至Internal Server Error。我借同学的电脑运行也是同样的问题,这该怎么解决?main.py运行报错如下:
127.0.0.1 - - [11/Oct/2021 21:58:52] "GET / HTTP/1.1" 200 - search error [2021-10-11 21:58:54,831] ERROR in app: Exception on /search/ [POST] Traceback (most recent call last): File "C:\Users\15992\Desktop\newsmaster\venv\lib\site-packages\flask\app.py", line 2073, in wsgi_app response = self.full_dispatch_request() File "C:\Users\15992\Desktop\newsmaster\venv\lib\site-packages\flask\app.py", line 1519, in full_dispatch_request return self.finalize_request(rv) File "C:\Users\15992\Desktop\newsmaster\venv\lib\site-packages\flask\app.py", line 1538, in finalize_request response = self.make_response(rv) File "C:\Users\15992\Desktop\newsmaster\venv\lib\site-packages\flask\app.py", line 1701, in make_response raise TypeError( TypeError: The view function for 'search' did not return a valid response. The function either returned None or ended without a return statement. 127.0.0.1 - - [11/Oct/2021 21:58:54] "POST /search/ HTTP/1.1" 500 -