I have a scheduler that I have written in Perl and executes its jobs using open3 so that it can capture both outputs seperately. The jobs being executed are also Perl scripts. It runs more than 1500 jobs a day, but in reality, they are primarily only 3 different Perl scripts called with 500 different parameters each. So, the called jobs are well tested.

I've got probably better than a 98% success rate. Occasionally a job executed via the open3 will generate a pop-up window with the error "Windows Command Processor Has Stopped Working". I've put a print at the very end of each of the Perl scripts so I can verify that the job has made it to the exit, and the prints do get captured by the open3. However, the output streams don't close and the waitpid doesn't return until I click on the pop-up window to close it. Then the waitpid returns a non-zero status even though it appears to me that the job has run successfully to completion.

I'm on Windows 8, but this has been occurring since long before that.

Does any one know why I would get this failed Windows Command Processor error on an exit 0? And not that I want to hide the problem, but the scheduler will automatically retry, so is there anyway I could avoid this pop-up on the failure because otherwise it hangs until I click on it?


In reply to open3 generates Windows Command Processor Has Stopped Working by DanEllison

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.