#10627: Middleware using len() on response.content is gobbling generators -------------------------------------+-------------------------------------- Reporter: FunkyBob | Owner: nobody Status: new | Milestone: Component: Core framework | Version: SVN Resolution: | Keywords: middleware Stage: Unreviewed | Has_patch: 1 Needs_docs: 0 | Needs_tests: 0 Needs_better_patch: 0 | -------------------------------------+-------------------------------------- Changes (by FunkyBob):
* needs_better_patch: => 0 * needs_tests: => 0 * needs_docs: => 0 Comment: I realise there are other approaches I could have taken with gzip, but I took the "simple and safe" path. I expect more discussion would be wanted on how to approach the problem ... such as: 1. How do you determine if the content from a generator will be worth compressing, or do you just always try/never try? 2. Do we want the gzip layer consuming generators and compressing, or leave them alone? In our case, we leave it up to Apache to gzip any content we ask of it, so it's a non-issue. -- Ticket URL: <http://code.djangoproject.com/ticket/10627#comment:1> Django <http://code.djangoproject.com/> The Web framework for perfectionists with deadlines. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django updates" group. To post to this group, send email to django-updates@googlegroups.com To unsubscribe from this group, send email to django-updates+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-updates?hl=en -~----------~----~----~----~------~----~------~--~---