Unusual minidom behaviour: Part Deux

Victor Bazarov vAbazarov at dAnai.com
Thu Jul 26 13:04:46 EDT 2001


"Guido van Rossum" <guido at python.org> wrote...
> [..]
> Victor, we don't have enough information.  Are you using Jython, or
> are you somehow invoking C-Python from Java?  Can you reproduce the
> problem in a self-contained example program?


I am not using Jython.  I am running a regular one (if it's called
C-Python, I didn't know) from Java using Runtime.exec("python
 something.py").  Its version is 2.0 (at least that's what it
reports when run with -V).

I cannot always reproduce the problem in my _current_ system (it
only happens in some runs), much less in a whole another program.

In order to write a test program I have to know what to try to
reproduce.  Should it itself be multi-threaded?  How complex should
it be?  If I don't get the same result, does it mean the problem is
in my Java program or is it just a coincidence?  (as I wrote before,
it does not happen if I run Java program under the debugger instead
of simply executing it)  You see, it would probably take me as long
to create a "self-contained" example as it did to create the system
in its current state.

One of my colleagues suggested wrapping the call to minidom.parse
in a critical section (locking something before, unlocking after),
another hint came from you: let the main program sleep after fork.
At this point I frankly care only about one thing: to prevent it
from happening.

Victor
--
Please remove capital A's from my address when replying by mail





More information about the Python-list mailing list