Antoine Pitrou <pit...@free.fr> added the comment:

> Doing so would imply running each test many tens of thousands of
> times, so perhaps we could run "-c pass" to establish at what serialno
> the interpreter has fully started up, then use that as a starting
> point when testing other scripts/modules.

Well, this seems to suggest it's not an optimal approach. IMHO, your
sys._inject_malloc_failure() proposal sounded better.

(I don't think running "-c pass" is an appropriate solution; it's not
obvious that the number of memory allocations at startup is totally
deterministic - it could depend on e.g. I/O conditions -, and I don't
think we want to ensure it is)

> Running this interactively with a large value for
> PYTHONMALLOCINJECTFAULTSAT

I don't think an env variable is useful for this, since you probably
don't want to set it permanently or even semi-permanently (and
"PYTHONLONGUNAMBIGUOUSVARIABLENAME"s are always painful :-)). The new -X
option support could be used instead, if a sys function isn't enough.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue10195>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to