On 25 mars 2013, at 18:02, SteveB <[email protected]> wrote:
> I suspect this is a bug. Any thoughts?
Yes, it's annoying, all the more since Django exposes response.content as an
attribute.
> This works, but makes my code dependent on the internals of the HttpResponse
> class, which isn't great. Any better ideas?
I assume you're pickling the response to cache it. We could define a
__getstate__ method to remove _iterator from what's pickled, like this:
def __getstate__(self):
state = self.__dict__.copy()
state.pop('_iterator', None)
return state
Could you file a ticket so we don't lose track of this problem?
--
Aymeric.
--
You received this message because you are subscribed to the Google Groups
"Django developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/django-developers?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.