Opened 9 years ago

Closed 6 years ago

#3398 defect closed fixed (fixed)

process cleanup for ReactorBuilder-based tests loops indefinitely if processes do not exit

Reported by: zooko Owned by: Itamar Turner-Trauring
Priority: normal Milestone:
Component: core Keywords:
Cc: Jean-Paul Calderone Branch: branches/process-cleanup-loop-3398-2
branch-diff, diff-cov, branch-cov, buildbot
Author: itamarst, exarkun

Description

http://buildbot.twistedmatrix.com/builders/cygwin-py2.5-select/builds/1

Produces many hundreds or thousands of this line in the test.log:

2008-08-26 15:29:02-0700 [-] ReactorBuilder.tearDown reaping some processes {2540: <PTYProcess pid=2540 status=-1>}

Followed by many of this:

2008-08-26 15:29:10-0700 [-] ReactorBuilder.tearDown reaping some processes {2524: <PTYProcess pid=2524 status=-1>}

and eventually I stopped it.

Change History (12)

comment:1 Changed 9 years ago by Jean-Paul Calderone

Cc: Jean-Paul Calderone added

It seems the process started by twisted.internet.test.test_process.ProcessTestsBuilder_PollReactor.test_childConnectionLost never exits. It is supposed to exit when it receives a blank line on stdin, which the test sends it after sending two other lines.

It seems like the test method actually ran to completion and all the events it expected did happen because the infinite log message happens in tearDown which should only run after the test method has returned.

So the question here may be about why the child process isn't exiting when it is expected to.

comment:2 Changed 9 years ago by zooko

Maybe it is waiting for a DOS-style blank line: '\r\n' ?

comment:3 Changed 9 years ago by Jean-Paul Calderone

Maybe. I don't have cygwin installed anywhere, so I can't test this.

comment:4 Changed 9 years ago by zooko

Resolution: duplicate
Status: newclosed

duplicate of #3529

comment:5 Changed 9 years ago by Jean-Paul Calderone

Resolution: duplicate
Status: closedreopened

Even if cygwin is broken, the tests shouldn't get stuck in a loop. #3529 can be for fixing cygwin support somehow. I'm using this ticket to fix the getting stuck behavior.

comment:6 Changed 9 years ago by Jean-Paul Calderone

Owner: changed from Glyph to Jean-Paul Calderone
Status: reopenednew

comment:7 Changed 9 years ago by Jean-Paul Calderone

Author: exarkun
Branch: branches/process-cleanup-loop-3398

(In [25347]) Branching to 'process-cleanup-loop-3398'

comment:8 Changed 9 years ago by Jean-Paul Calderone

Owner: changed from Jean-Paul Calderone to zooko
Summary: cygwin unit tests stuck in loopprocess cleanup for ReactorBuilder-based tests loops indefinitely if processes do not exit

Can you try the branch on cygwin?

I expect the tests will fail, but the suite should run to completion at least.

comment:9 Changed 6 years ago by Itamar Turner-Trauring

Owner: changed from zooko to Itamar Turner-Trauring

comment:10 Changed 6 years ago by Itamar Turner-Trauring

Keywords: cygwin removed

comment:11 Changed 6 years ago by itamarst

Author: exarkunitamarst, exarkun
Branch: branches/process-cleanup-loop-3398branches/process-cleanup-loop-3398-2

(In [34151]) Branching to 'process-cleanup-loop-3398-2'

comment:12 Changed 6 years ago by itamarst

Resolution: fixed
Status: newclosed

(In [34153]) Merge process-cleanup-loop-3398-2: Cleanup after zombie test processes.

Author: exarkun Review: itamar Fixes: #3398

Hopefully this will make the Fedora buildbot stop getting into infinite loops.

Note: See TracTickets for help on using tickets.