On Sun, Mar 29, 2009 at 2:12 PM, Kurt Grandis <[email protected]> wrote:
> http://code.djangoproject.com/ticket/9986
>
>
> This ticket proposes reconciling the code's parameter name, cull_frequency,
> with the docs' cull_probability; the ticket proposes standardizing on
> cull_probability, which I think would be misleading.
>
>
> The code where cull_frequency actually does its magic shows that it is used
> in frequency calculations:
>
> doomed = [os.path.join(self._dir, k) for (i, k) in enumerate(filelist) if i
> % self._cull_frequency == 0]
>
> and
>
> doomed = [k for (i, k) in enumerate(self._cache) if i % self._cull_frequency
> == 0]
>
> The default cull_frequency is 3, so the above code would flag every 3rd item
> as doomed (1/f or 1/3). While cull_frequency is a more accurate description,
> I don't think it is intuitive without seeing the underlying code.
> cull_fraction might be a more appropriate and intuitive parameter name (e.g.
> what fraction of the cache gets culled).
>
> cull_fraction?

All of those are misleading, since they actually describe the
reciprocal of the parameter.  As long as we're open to changing it, I
suggest using cull_interval instead.

Regards,
Ian

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django developers" 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-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to