[mozprocess] mozprocess ProcessReader waits for stdout/stderr threads after timeout
Categories
(Testing :: Mozbase, defect, P3)
Tracking
(Not tracked)
People
(Reporter: gbrown, Unassigned)
References
(Depends on 1 open bug)
Details
Attachments
(1 file)
|
402 bytes,
text/plain
|
Details |
| Reporter | ||
Comment 1•8 years ago
|
||
| Reporter | ||
Comment 2•8 years ago
|
||
Comment 3•7 years ago
|
||
| Reporter | ||
Comment 4•7 years ago
|
||
Comment 5•7 years ago
|
||
Comment 6•7 years ago
|
||
Updated•7 years ago
|
Comment 7•7 years ago
|
||
Comment 8•7 years ago
|
||
Updated•7 years ago
|
Comment 9•7 years ago
|
||
| Reporter | ||
Updated•6 years ago
|
| Reporter | ||
Comment 10•6 years ago
|
||
Looking at bug 1521447 and bug 1535695 recently, this issue came up again: On Windows 7, in marionette restart tests, sometimes a child process appears to hang after kill(). If we abandon subsequent process waits with timeouts, the process_handler ends up waiting for the ProcessReader, which is hung on readline().
| Reporter | ||
Comment 11•6 years ago
|
||
(In reply to Geoff Brown [:gbrown] from comment #2)
(In reply to Geoff Brown [:gbrown] from comment #1)
Close the stream??
I tried closing stdout/stderr from another thread (threading.Timer), but it
didn't work. It just threw:IOError: close() called during concurrent operation on the same file object.
and left the reader thread blocked on readline().
I realized I need to use a lock to guard the stdout/stderr stream access; then another thread can close the streams, and readline() is unblocked.
| Reporter | ||
Comment 12•6 years ago
|
||
(In reply to Geoff Brown [:gbrown] from comment #11)
I realized I need to use a lock to guard the stdout/stderr stream access; then another thread can close the streams, and readline() is unblocked.
Lock allows another thread to safely access the stream. BUT, the stream readline needs to be guarded by the Lock too, of course, so in the case where readline blocks, the other thread cannot acquire the lock to close the stream -- we just achieve another deadlock.
Updated•3 years ago
|
Comment 13•3 years ago
|
||
The severity field for this bug is relatively low, S3. However, the bug has 5 See Also bugs.
:gbrown, could you consider increasing the bug severity?
For more information, please visit auto_nag documentation.
| Reporter | ||
Comment 14•3 years ago
|
||
I think the See Also bugs reflect the issue's complexity. S3 seems appropriate.
Description
•