On Mon, 2011-02-21 at 19:05 +0200, Panu Matilainen wrote: > On 02/21/2011 06:34 PM, James Antill wrote: > > + if varname != 'hdr': # Don't cache the hdr, unless explicitly > > requested
> The question to me is, is there actually ever a "valid" case to cache > the header in the package object? If somebody asks fo po.hdr, they > already get a reference to it, and can then do whatever they please with > it. Eg My assumption is that we didn't want to break: hdr = po.hdr # [...] if id(hdr) == id(po.hdr): ...and while I doubt there's anything that will break if we change that, I also doubt there should be any callers accessing .hdr directly (at least ones who don't need to be fixed :). And having the problem from the bad assumption be that we use more memory (rather than do something wrong) should make Seth happier :). The fact the changelog plugin currently does "times = po.hdr['changelogtime']" is unfortunate, but can be fixed easily. You disagree with any of the above? _______________________________________________ Yum-devel mailing list [email protected] http://lists.baseurl.org/mailman/listinfo/yum-devel
