for wsgi and large files, it would be cool to be able to just return an open file handler or a generator or iterator and wsgi will iterate through it correctly and return it.
I'd like to see this work:
class Foo(Controller):
def GET(self):
fp = open("/some/path.ext", 'rb')
return fp
I'd also love to see support for this working:
class Foo(Controller):
def GET(self):
for x in range(100):
yield x
This would involve modifying the simple server to work similar to uwsgi also, where yield doesn't finish the request like it currently does, I'm cool with that though since we removed Mongrel2 support. This would allow us to get rid of all that hacky generator code also which would simplify Call quite a bit
for wsgi and large files, it would be cool to be able to just return an open file handler or a generator or iterator and wsgi will iterate through it correctly and return it.
I'd like to see this work:
I'd also love to see support for this working:
This would involve modifying the simple server to work similar to uwsgi also, where yield doesn't finish the request like it currently does, I'm cool with that though since we removed Mongrel2 support. This would allow us to get rid of all that hacky generator code also which would simplify Call quite a bit