Development server with django.views.static.serve route, file has 235949884 bytes. When trying to access the file, I get the following error:
Traceback (most recent call last):
File "D:\Python25\lib\site-packages\django\core\servers\basehttp.py", line 279, in run
self.finish_response()
File "D:\Python25\lib\site-packages\django\core\servers\basehttp.py", line 318, in finish_response
self.write(data)
File "D:\Python25\lib\site-packages\django\core\servers\basehttp.py", line 402, in write
self._write(data)
File "D:\Python25\lib\socket.py", line 263, in write
self.flush()
File "D:\Python25\lib\socket.py", line 250, in flush
self._sock.sendall(buffer)
error: (10055, 'No buffer space available')
Django seems to be able to read and write the file. In flush() in socket.py the final buffer to flush has the correct size. Please tell me that this isn't a general Python error. It should be possible to write a 230MB file into a socket. Still, it might be better if serve() would *not* try to read in everything at once and then write everything but stream the file in smaller chunks.