首页 > 其他分享 >flask 接口无法连接

flask 接口无法连接

时间:2022-08-29 19:44:41浏览次数:59  
标签:flask 无法访问 接口 无法 debug 连接

flask 运行一段时间后出现接口无法访问:本地+远程都无法访问该接口服务,top,pstress -ap 可以看到服务在运行,后台log没有异常

死锁的感觉,请求该接口返回如下:

ConnectionError: HTTPConnectionPool(host=‘127.0.0.1’, port=5000): Max retries exceeded with url: (Caused by NewConnectionError(’<urllib3.connection.HTTPConnection object xxx>: Failed to establish a new connection: [Errno -2] Name or service not known’))

疑似flask 启的时候是debug模式,该系统定期更新模型受到影响 ?
目前将debug设置为false还没有再碰到服务无法连接的情况

我遇到这种情况,的确是关闭了debug模式就可以了,

标签:flask,无法访问,接口,无法,debug,连接
From: https://www.cnblogs.com/andy0816/p/16637129.html

相关文章