Regardless of whether we come up with a general solution (seems of doubtful use to me), linecache really is last-century technology. :-(

On Wed, Apr 1, 2015 at 8:32 AM, Andrew Barnert <abarnert@yahoo.com.dmarc.invalid> wrote:
On Apr 1, 2015, at 08:18, Eric Snow <ericsnowcurrently@gmail.com> wrote:
>
> On Wed, Apr 1, 2015 at 8:37 AM, Andrew Barnert
> <abarnert@yahoo.com.dmarc.invalid> wrote:
>> Anyway, why do you want this? Is there some cache that's using too much memory in an app of yours? Or is it more about getting a semi-clean start on the interactive interpreter? Or something different?
>
> Presumably http://bugs.python.org/issue23839.

Ah, for running a large test suite (like the stdlib's). That makes sense.

>From the initial report ("in particular linecache") it seems at least possible that there's really just one cache that's a real issue, in which case there's a pretty obvious fix. (And making it possible to use linecache in a bounded way, instead of all-or-nothing clearing, might be useful for other purposes besides this...) But I don't know if that really is the case; did anyone check whether the 500MB were 90%+ in linecache or anything like that?
_______________________________________________
Python-ideas mailing list
Python-ideas@python.org
https://mail.python.org/mailman/listinfo/python-ideas
Code of Conduct: http://python.org/psf/codeofconduct/



--
--Guido van Rossum (python.org/~guido)