forked from goodboy/tractor
1
0
Fork 0

Handle nested multierror case on windows

immediate_remote_cancels
Tyler Goodlet 2021-10-15 09:16:51 -04:00
parent 51259c4809
commit 533457c64d
1 changed files with 7 additions and 3 deletions

View File

@ -1,5 +1,6 @@
"""
Cancellation and error propagation
"""
import os
import signal
@ -377,10 +378,13 @@ async def test_nested_multierrors(loglevel, start_method):
elif isinstance(subexc, trio.MultiError):
for subsub in subexc.exceptions:
assert subsub.type in (
tractor.RemoteActorError,
if subsub in (tractor.RemoteActorError,):
subsub = subsub.type
assert subsub in (
trio.Cancelled,
trio.MultiError
trio.MultiError,
)
else:
assert isinstance(subexc, tractor.RemoteActorError)