Yeah, I did some digging in the TurboGears and TurboKid source code this morning. Kid does indeed support using an iterator. And CherryPy does support receiving one. But TurboKid (the part in the middle that expose calls to process Kid templates) uses the serialize() method (return one big string), rather then the generate() method.
So if you want to return streaming data from a kid template you will have to do the Kid template processing yourself and return the results from it's generate method. It seems like it would be a simple patch to TurboKid to make is use generate instead, but I don't know if there would be any negative consequences to the change. Good call on the CherryPy configuration setting! I have forgot about the buffering. It's nice to know that streaming is possible and that you do not have to do the ugly hack that I had previously proposed. You just have to process them template manually, which is not that hard really. Anyway, I hope this helps. Krys On Apr 4, 10:00 am, "Joost Moesker" <[EMAIL PROTECTED]> wrote: > Kid output can be incrementally generate using the .generate() method > instead of .render() (e.g, template.generate(output="html", > encoding="ISO-8859-1")).. > > Normally cherrypy will buffer all the output before sending it to the > client. You can set the configuration option stream_response to True > to enable streaming. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "TurboGears" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/turbogears?hl=en -~----------~----~----~----~------~----~------~--~---

