Issue #219: waitress exception when serving file (conservancy/kallithea)
fragpit
issues-reply at bitbucket.org
Tue May 24 11:14:37 UTC 2016
New issue 219: waitress exception when serving file
https://bitbucket.org/conservancy/kallithea/issues/219/waitress-exception-when-serving-file
fragpit:
Hello,
faced with exeption:
```
#!python
2016-05-24 09:01:30.601 ERROR [waitress] uncaptured python exception, closing channel <waitress.server.TcpWSGIServer listening 0.0.0.0:5000 at 0x7f2c0050f610> (<class 'socket.error'>:[Errno 9] Bad file descriptor [/usr/lib/python2.7/asyncore.py|read|83] [/usr/lib/python2.7/asyncore.py|handle_read_event|443] [/usr/local/lib/python2.7/dist-packages/waitress-0.8.8-py2.7.egg/waitress/server.py|handle_accept|147] [/usr/local/lib/python2.7/dist-packages/waitress-0.8.8-py2.7.egg/waitress/channel.py|__init__|80] [/usr/lib/python2.7/asyncore.py|__init__|250] [/usr/lib/python2.7/socket.py|meth|224])
2016-05-24 09:01:30.601 WARNI [waitress] unhandled close event
2016-05-24 09:01:30.608 ERROR [waitress] Exception when serving /Library-Android/skia/libwebp.git/git-upload-pack
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/waitress-0.8.8-py2.7.egg/waitress/channel.py", line 337, in service
task.service()
File "/usr/local/lib/python2.7/dist-packages/waitress-0.8.8-py2.7.egg/waitress/task.py", line 173, in service
self.execute()
File "/usr/local/lib/python2.7/dist-packages/waitress-0.8.8-py2.7.egg/waitress/task.py", line 424, in execute
self.write(chunk)
File "/usr/local/lib/python2.7/dist-packages/waitress-0.8.8-py2.7.egg/waitress/task.py", line 307, in write
channel.write_soon(towrite)
File "/usr/local/lib/python2.7/dist-packages/waitress-0.8.8-py2.7.egg/waitress/channel.py", line 319, in write_soon
self.outbufs[-1].append(data)
File "/usr/local/lib/python2.7/dist-packages/waitress-0.8.8-py2.7.egg/waitress/buffers.py", line 253, in append
self._set_large_buffer()
File "/usr/local/lib/python2.7/dist-packages/waitress-0.8.8-py2.7.egg/waitress/buffers.py", line 236, in _set_large_buffer
self.buf = TempfileBasedBuffer(self.buf)
File "/usr/local/lib/python2.7/dist-packages/waitress-0.8.8-py2.7.egg/waitress/buffers.py", line 116, in __init__
FileBasedBuffer.__init__(self, self.newfile(), from_buffer)
File "/usr/local/lib/python2.7/dist-packages/waitress-0.8.8-py2.7.egg/waitress/buffers.py", line 120, in newfile
return TemporaryFile('w+b')
File "/usr/lib/python2.7/tempfile.py", line 498, in TemporaryFile
_os.close(fd)
OSError: [Errno 9] Bad file descriptor
```
Kallithea sometimes fails on pulling file from same folder.
I can't reproduce it manually by executing 'git clone'.
More information about the kallithea-general
mailing list