#16022: Cyclic reference in FieldFile
-------------------------------------+-------------------------------------
Reporter: Gustavo | Owner: nobody
Type: Bug | Status: new
Milestone: | Component: Database layer
Version: 1.1 | (models, ORM)
Resolution: | Severity: Normal
Triage Stage: | Keywords:
Unreviewed | Has patch: 1
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
-------------------------------------+-------------------------------------
Comment (by Gustavo):
I've tried replacing weakref.ref() with weakref.proxy(), which does work
but then memory keeps growing as usual. I think a proper way to fix it is
to break the cyclic reference, but that'd be backwards incompatible.
I cannot afford spending more time on this, so I'll leave it to someone
else. I'm happy to test any eventual fix though. In the meantime, we'll be
using mod_wsgi's ''maximum-requests'' to mitigate the consequences of this
problem.
A hint to whoever will have a look at this: Try setting ''self.instance''
to ''None'' in ''!FieldFile.!__init!__'' and you won't notice any memory
growth when you query many records. This breaks creation, modification and
deletion of files, but helps demonstrate that this is the problematic
reference.
--
Ticket URL: <https://code.djangoproject.com/ticket/16022#comment:2>
Django <https://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 [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/django-updates?hl=en.