> I'm not sure I understand this remark.  I don't think it's used in Leo
> for any other purpose.  Am I wrong?

C.db is the pickleshare instance. Caching is not the only thing it's used for.


>
> Do you mean that pickleshare is more reliable than one might think
> because it is used in other projects?  That may be so, but it hasn't
> been updated recently, and there were crashers that I had to fix in it
> to make it work with Python 3x.

I mean pickleshare has some safeguards for concurrent use (e.g. Many leo 
processes using it at the same time). Probably not critical.

> uses pickleshare.py.    It remains to be seen whether this can be done
> without altering pickleshare.py.  But with my newly acquired knowledge
> that should be possible without risking wholesale changes.

You can accomplish what you want by c.db.keys('fcache/*') and del c.db(key). 
Just add file name to hash file name (a.txt_56546788) and go from there.

> This distinction is important here.  I consider Leo's caching code to
> have a memory leak: it's creating too many files in .leo/db.  This bug
> should be fixed for rc1.  But fixing that bug should not require huge
> changes to pickleshare.py, and it would be inappropriate now to make
> those changes unless they are necessary.

I think this is a somewhat minor problem, it leaks extremely slowly... New 
entries are only created when a file has been changed and you restart leo. 
Improving it is a good thing, but not too critical. Clean-cache command could 
be better actually, as it would also clean up cache files from old leo files 
(that are no longer actively edited).

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" 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/leo-editor?hl=en.

Reply via email to