Skip to content

Commit

Permalink
Fix #2497: Ignore NotImplementedError raised by set_child_watcher fro…
Browse files Browse the repository at this point in the history
…m uvloop.
  • Loading branch information
asvetlov committed Nov 10, 2017
1 parent 7e15124 commit 0eaa475
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGES/2497.bugfix
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Ignore `NotImplementedError` raised by `set_child_watcher` from `uvloop`.
3 changes: 2 additions & 1 deletion aiohttp/test_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -452,7 +452,8 @@ def setup_test_loop(loop_factory=asyncio.new_event_loop):
policy = asyncio.get_event_loop_policy()
watcher = asyncio.SafeChildWatcher()
watcher.attach_loop(loop)
policy.set_child_watcher(watcher)
with contextlib.suppress(NotImplementedError):
policy.set_child_watcher(watcher)
return loop


Expand Down

0 comments on commit 0eaa475

Please sign in to comment.