Skip to content

Commit

Permalink
Spawn even less suba-actors in Windows CI
Browse files Browse the repository at this point in the history
Seems like we've probably got some greater limitations
with Windows and "nested" spawned sub-processes...
  • Loading branch information
goodboy committed Nov 23, 2019
1 parent f977d37 commit 2d4b6de
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions tests/test_cancellation.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Cancellation and error propagation
"""
import platform
from itertools import repeat

import pytest
Expand Down Expand Up @@ -87,7 +88,6 @@ async def main():
tractor.run(main, arbiter_addr=arb_addr)



@pytest.mark.parametrize('delay', (0, 0.5))
@pytest.mark.parametrize(
'num_subactors', range(25, 26),
Expand Down Expand Up @@ -270,19 +270,20 @@ async def spawn_and_error(num) -> None:
)


@pytest.mark.parametrize(
'num_subactors',
# NOTE: any more then this and the forkserver will
# start bailing hard...gotta look into it
range(4, 5),
ids='{}_subactors'.format,
)
@tractor_test
async def test_nested_multierrors(loglevel, num_subactors, start_method):
async def test_nested_multierrors(loglevel, start_method):
"""Test that failed actor sets are wrapped in `trio.MultiError`s.
This test goes only 2 nurseries deep but we should eventually have tests
for arbitrary n-depth actor trees.
"""
if platform.system() == 'Windows':
# Windows CI seems to be partifcularly fragile on Python 3.8..
num_subactors = 2
else:
# XXX: any more then this and the forkserver will
# start bailing hard...gotta look into it
num_subactors = 4

try:
async with tractor.open_nursery() as nursery:

Expand Down

0 comments on commit 2d4b6de

Please sign in to comment.