Changes by Robert Cronk :
--
nosy: +rcronk
___
Python tracker
<http://bugs.python.org/issue1652>
___
___
Python-bugs-list mailing list
Unsubscribe:
Robert Cronk added the comment:
Could this problem be associated with issue4749? It was found that
something goes wrong when two cmd children processes are spawned from
different threads, when the first exits, it is closing file handles
shared with the first (or something like that) and
Robert Cronk added the comment:
One more possibly related bug is issue2320 where subprocesses are
spawned from multiple threads. They found an interesting workaround
that I found seems to help our problem too: "on Windows, if close_fds
is true then no handles will be inherited by the
Robert Cronk added the comment:
I found Issue1425127 which may be a different symptom of this core
problem. I suggested that we create a bug that documents the core
problem here as described by Vinay in msg89174 and links to these two
bugs (along with any others we find) as examples of the
Robert Cronk added the comment:
Could this problem be associated with issue4749? It was found that
something goes wrong when two cmd children processes are spawned from
different threads, when the first exits, it is closing file handles
shared with the first (or something like that) and
Robert Cronk added the comment:
I changed the script to use subprocess (attached file) and got the same
rollover errors as before. I had to change cd and del to be cd.bat and
del.bat which contained cd %1 and del %1 respectively since it appears
subprocess can't run internal commands
Robert Cronk added the comment:
Vinay - that's great news! Are you going to create a new bug for this issue
with a proper title? It would seem to me that the fix for this would be to put
locks internal to the os.system() call around where it spawns cmd so multiple
spawns don
Robert Cronk added the comment:
I turned off anti-virus again as well as file indexing and google
desktop too and still got the errors when I disabled the locks around
the os.system() calls.
Vinay - when the locks aren't around the os.system() calls, do you get
the rotating log errors?
Robert Cronk added the comment:
I'll thoroughly look through every piece of software that's running to
see if I can turn eveything off that might be causing the problem.
Were you able to reproduce the problem with my original script? I'm
sure you have all of your virus/searc
Robert Cronk added the comment:
Thanks Vinay. I ran the newest revised script with virus protection
turned off and got the same failures as before (see console output
below).
If you comment out the os.system() calls, everything works just fine.
Uncomment them and logging breaks.
The
Robert Cronk added the comment:
I didn't care about the os.system() call contention because that's what
caused the logging problem and that blah.txt file contention should not
cause logging to fail.
I also had the join calls originally but took them out to simplify the
code since
Robert Cronk added the comment:
I just upgraded to 2.6.2 windows from python.org and it fails as well:
Python 2.6.2 (r262:71605, Apr 14 2009, 22:40:02) [MSC v.1500 32 bit
(Intel)] on win32
I hope Vinay can track this down in case it's a race condition that's
just moving arou
Robert Cronk added the comment:
Thanks Lowell - good information. You have many more versions of
Python "laying around" than I do. ;)
--
___
Python tracker
<http://bugs.python.
Robert Cronk added the comment:
P.S. Frans - It's good to get these other data points from you. So
this is reproducible from another person and on different versions of
python AND on different platforms! I wasn't expecting that at all.
Thanks Frans.
Is there a way we can reope
Robert Cronk added the comment:
>>> import sys
>>> print sys.version
2.6.1 (r261:67517, Dec 4 2008, 16:51:00) [MSC v.1500 32 bit (Intel)]
I have seen this behavior in older versions as well. Interesting to
see it fai
Robert Cronk added the comment:
P.S. The above script and failure is running on winxp sp3. Also, if
you comment out the two os.system() calls, it works just fine. They
seem like they should be unrelated to the logging though. You'll also
see some errors about access to the blah.txt
Robert Cronk added the comment:
I have a small script that reproduces the problem. I couldn't
reproduce it until I added some os.system() calls in the threads that
were logging. Here's the output using python 2.6.1:
Traceback (most recent call last):
File "C:\Pytho
Robert Cronk added the comment:
I will go through the code and make sure I am not mistaken, but I do
believe I have a single process, multiple threads, and only one handler
for this file and I'm getting the same types of error messages shown on
this page. I'm probably doing somet
Robert Cronk added the comment:
I have had this problem with 2.6.1 on windows from multiple _threads_
instead of multiple processes. Is that not supported either? If not,
what is the workaround for logging from multiple threads? Shouldn't it
be easy to use a semaphore within the lo
19 matches
Mail list logo