2007年09月30日 星期日 09:34
Jiahua Huang,您好! 呵呵,又是这个问题,accept的时候没有判断有系统中断的情况。 ======= 2007-09-30 09:20:35 您在来信中写道:======= >嗯,是这些输出 >http://paste.ubuntu.org.cn/2488 > >web.py 单独运行一段时间后,输出 >Traceback (most recent call last): > File "./demo.py", line 109, in> if __name__ == "__main__": web.run(urls, globals(), web.reloader) > File "/home/huahua/work/se/web/request.py", line 145, in run > return wsgi.runwsgi(webapi.wsgifunc(webpyfunc(inp, fvars, >autoreload), *middleware)) > File "/home/huahua/work/se/web/wsgi.py", line 54, in runwsgi > return httpserver.runsimple(func, validip(listget(sys.argv, 1, ''))) > File "/home/huahua/work/se/web/httpserver.py", line 221, in runsimple > server.start() > File "/home/huahua/work/se/web/wsgiserver/__init__.py", line 869, in start > self.tick() > File "/home/huahua/work/se/web/wsgiserver/__init__.py", line 896, in tick > s, addr = self.socket.accept() > File "/usr/lib/python2.5/socket.py", line 167, in accept > sock, addr = self._sock.accept() >socket.error: (4, 'Interrupted system call') > >然后浏览器里就连不上了 > >在 07-9-30,Yingbo Qiu<qiuyingbo在gmail.com> 写道: >> >> 崩溃?是程序异常终止么? >> >> 关注ing.. >_______________________________________________ >python-chinese >Post: send python-chinese在lists.python.cn >Subscribe: send subscribe to python-chinese-request在lists.python.cn >Unsubscribe: send unsubscribe to python-chinese-request在lists.python.cn >Detail Info: http://python.cn/mailman/listinfo/python-chinese = = = = = = = = = = = = = = = = = = = = 致 礼! 赵威 zhaowei在pythonid.com 2007-09-30
2007年09月30日 星期日 09:40
后来用的这个 http://paste.ubuntu.org.cn/3391 --- web/wsgiserver/__init__.py.orig 2007-06-20 09:37:07.000000000 +0800 +++ web/wsgiserver/__init__.py 2007-06-20 09:37:40.000000000 +0800 @@ -866,7 +866,10 @@ self.ready = True while self.ready: - self.tick() + try: + self.tick() + except: + continue if self.interrupt: while self.interrupt is True: # Wait for self.stop() to complete. See _set_interrupt. 在 07-9-30,赵威<zhaowei at pythonid.com> 写道: > > 呵呵,又是这个问题,accept的时候没有判断有系统中断的情况。 >
2007年09月30日 星期日 10:24
有人提交 patch 给 CherryPy 么? http://www.cherrypy.org/wiki/CherryPyDownload webpy 用的是 3.0.1,刚刚看了看 3.0.2 和 trunk 中的 __init__.py 都还有这个隐患呢!
Zeuux © 2025
京ICP备05028076号