[ https://issues.apache.org/jira/browse/QPID-2294?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13872403#comment-13872403 ]
ASF subversion and git services commented on QPID-2294: ------------------------------------------------------- Commit 1558503 from [~gsim] in branch 'qpid/trunk' [ https://svn.apache.org/r1558503 ] QPID-2294: handle signal interruptions to select > The Unix python client can erroneously throw exceptions from select due to > interrupted system call > -------------------------------------------------------------------------------------------------- > > Key: QPID-2294 > URL: https://issues.apache.org/jira/browse/QPID-2294 > Project: Qpid > Issue Type: Bug > Components: Python Client > Affects Versions: 0.6 > Environment: Red Hat Enterprise Linux 5.4 > Reporter: Andrew Stitcher > Assignee: Rafael H. Schloming > > When running autotools "make check" > You can cause the python_tests to fail in the qpid.tests.messaging section > (and perhaps elsewhere) by resizing the window that is running the tests. > You get something like this: > qpid.tests.messaging.SenderTests.testSendAsyncCapacityUNLIMITED > ............................ fail > Error during test: > Traceback (most recent call last): > File > "/home/astitche/bld-working/src/tests/python/commands/qpid-python-test", line > 307, in run > phase() > File > "/home/astitche/bld-working/src/tests/python/qpid/tests/messaging.py", line > 796, in testSendAsyncCapacityUNLIMITED > self.asyncTest(UNLIMITED) > File > "/home/astitche/bld-working/src/tests/python/qpid/tests/messaging.py", line > 777, in asyncTest > drained = self.drain(self.rcv, timeout=self.delay()) > File > "/home/astitche/bld-working/src/tests/python/qpid/tests/messaging.py", line > 84, in drain > contents.append(rcv.fetch(timeout=timeout).content) > File "<string>", line 6, in fetch > File "/home/astitche/bld-working/src/tests/python/qpid/messaging.py", > line 668, in fetch > msg = self.session._get(self._pred, timeout=timeout) > File "<string>", line 6, in _get > File "/home/astitche/bld-working/src/tests/python/qpid/messaging.py", > line 360, in _get > timeout): > File "/home/astitche/bld-working/src/tests/python/qpid/messaging.py", > line 294, in _ewait > result = self.connection._ewait(lambda: self.error or predicate(), > timeout, exc) > File "/home/astitche/bld-working/src/tests/python/qpid/messaging.py", > line 142, in _ewait > result = self._wait(lambda: self.error or predicate(), timeout) > File "/home/astitche/bld-working/src/tests/python/qpid/messaging.py", > line 131, in _wait > return self._waiter.wait(predicate, timeout=timeout) > File "/home/astitche/bld-working/src/tests/python/qpid/concurrency.py", > line 59, in wait > self.condition.wait(timeout - passed) > File "/home/astitche/bld-working/src/tests/python/qpid/concurrency.py", > line 96, in wait > sw.wait(timeout) > File "/home/astitche/bld-working/src/tests/python/qpid/compat.py", line > 53, in wait > ready, _, _ = select([self], [], [], timeout) > error: (4, 'Interrupted system call') > The cause is that python is receiving the SIGWINCH signal from the window > size change and this is interrupting the select system call. The exception > that is being thrown by select is not being caught. > This needs to be fixed as interrupted system calls are a fact of life when > running on Unix - you could argue that the python run time should just > restart the select, but it isn't doing that here. > Note that allowing for interrupted system calls screws up the timeout > calculation. As you'll need to figure out how much of the wait is left and > then wait for less time when restarting the system call. -- This message was sent by Atlassian JIRA (v6.1.5#6160) --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org For additional commands, e-mail: dev-h...@qpid.apache.org