Commit 58c160f5 authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent 53127d52
...@@ -438,14 +438,14 @@ class tWatch: ...@@ -438,14 +438,14 @@ class tWatch:
# XXX we can get stuck here if wcfs does not behave as we want. # XXX we can get stuck here if wcfs does not behave as we want.
# XXX in particular if there is a silly - e.g. syntax or type error in # XXX in particular if there is a silly - e.g. syntax or type error in
# test code - we curently get stuck here. # test code - we curently get stuck here.
print('# serveDone.recv() ...') #
# XXX -> better pthread_kill(SIGINT) instead of relying on wcfs proper behaviour?
try: try:
t._serveWG.wait() t._serveWG.wait()
except Exception as e: except Exception as e:
# canceled is expected and ok # canceled is expected and ok
if e != context.canceled: if e != context.canceled:
reraise(e, None, e.__traceback__) reraise(e, None, e.__traceback__)
print('# serveDone ready')
t.wtx.close() t.wtx.close()
t.wrx.close() t.wrx.close()
...@@ -462,7 +462,7 @@ class tWatch: ...@@ -462,7 +462,7 @@ class tWatch:
@func @func
def _serveRecv(t, ctx): def _serveRecv(t, ctx):
while 1: while 1:
print('C: watch : rx wait ...') # NOTE: .close() makes sure .wrx.read*() will wake up
l = t.wrx.readline() l = t.wrx.readline()
print('C: watch : rx: %r' % l) print('C: watch : rx: %r' % l)
if len(l) == 0: if len(l) == 0:
...@@ -565,7 +565,6 @@ class tWatch: ...@@ -565,7 +565,6 @@ class tWatch:
req = t.recvReq(ctx) req = t.recvReq(ctx)
except Exception as e: except Exception as e:
raise RuntimeError("%s\nnot all pin missages received - pending:\n%s" % (e, expected)) raise RuntimeError("%s\nnot all pin missages received - pending:\n%s" % (e, expected))
assert False # XXX temp
assert req is not None # channel not closed assert req is not None # channel not closed
assert req.msg in expected assert req.msg in expected
expected.remove(req.msg) expected.remove(req.msg)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment