From 05790a20c1abbb5bc4752263e83cdd6d69c826de Mon Sep 17 00:00:00 2001 From: Tyler Goodlet Date: Fri, 15 Jul 2022 11:18:48 -0400 Subject: [PATCH] Slight lint fixes --- tests/test_infected_asyncio.py | 4 +--- tractor/to_asyncio.py | 3 +-- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/tests/test_infected_asyncio.py b/tests/test_infected_asyncio.py index 979b558..976741d 100644 --- a/tests/test_infected_asyncio.py +++ b/tests/test_infected_asyncio.py @@ -14,7 +14,6 @@ import tractor from tractor import ( to_asyncio, RemoteActorError, - ContextCancelled ) from tractor.trionics import BroadcastReceiver @@ -199,7 +198,7 @@ def test_context_spawns_aio_task_that_errors( ''' Verify that spawning a task via an intertask channel ctx mngr that errors correctly propagates the error back from the `asyncio`-side - taksk. + task. ''' async def main(): @@ -223,7 +222,6 @@ def test_context_spawns_aio_task_that_errors( await trio.sleep_forever() - with pytest.raises(RemoteActorError) as excinfo: trio.run(main) diff --git a/tractor/to_asyncio.py b/tractor/to_asyncio.py index 0634215..a19afe1 100644 --- a/tractor/to_asyncio.py +++ b/tractor/to_asyncio.py @@ -23,7 +23,6 @@ from asyncio.exceptions import CancelledError from contextlib import asynccontextmanager as acm from dataclasses import dataclass import inspect -import traceback from typing import ( Any, Callable, @@ -297,7 +296,7 @@ def _run_asyncio_task( elif task_err is None: assert aio_err aio_err.with_traceback(aio_err.__traceback__) - log.error(f'infected task errorred') + log.error('infected task errorred') # XXX: alway cancel the scope on error # in case the trio task is blocking