Thanks a lot Honza and James!

On Jan 13, 2007, at 1:35 PM, Honza Král wrote:
just a thought: do you have DEBUG turned off in your settings?
if not, django will store all qeuries it made in memory so that it is
accessible for debugging purposes...

That's it! With debug off it's stable!!!!! Super.

On Jan 13, 2007, at 1:37 PM, James Bennett wrote:


On 1/13/07, Rob J Goedman <[EMAIL PROTECTED]> wrote:
Normally the delays are natural and are controlled via Twisted (TCP
and callLater). Above program is stable if I comment out the cpl=list
(...) statement, otherwise it grows forever.

Each time that code is called, it's fetching every row from the table
and instantiating a full in-memory model object for each row
retrieved; is there a reason why you need to have them all loaded and
instantiated at that moment, rather than waiting and iterating over
the QuerySet when you actually need to access the data?

In the actual code I do indeed iterate over query sets. Initially I hadn't
realized this but I noticed changing a panel to enable did not get
picked up. So I do not to force a refresh from the db each time around.
Luckily there are a limited set of control panels (<32 typically).

Thanks for the very quick answers!!

Rob
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Django 
users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to