Commit 2866081a authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent 3e4db57f
......@@ -982,7 +982,11 @@ def test_wcfs():
ev = []
def _(ctx):
print()
print('AAA')
raise RuntimeError('zzz')
pinv = wl._expectPin(ctx, zf, pinok)
print('BBB')
ev.append('pin rx')
tdelay() # XXX doc
......@@ -1006,8 +1010,21 @@ def test_wcfs():
ev.append('read pre')
# access data with released GIL so that the thread that reads data from
# head/watch can receive pin message.
b = read0_nogil(blk_data)
# head/watch can receive pin message. Be careful to handle cancelation,
# so that on error in another worker we don't stuck and the error is
# successfully propagated to wait and reported.
have_read = chan(1)
def _():
b = read0_nogil(blk_data)
have_read.send(b)
go(_)
_, _rx = select(
ctx.done().recv, # 0
have_read.recv, # 1
)
if _ == 0:
raise ctx.err()
b = _rx
ev.append('read ' + chr(b))
# cancel _expectPin waiting upon waking up from read from wcfs
......
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