Slight lint fixes

aio_error_propagation^2
Tyler Goodlet 2022-07-15 11:18:48 -04:00
parent 565c603300
commit 05790a20c1
2 changed files with 2 additions and 5 deletions

View File

@ -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)

View File

@ -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