Skip to content

Commit e3d10d8

Browse files
committed
yapf
1 parent aad3e71 commit e3d10d8

File tree

4 files changed

+5
-7
lines changed

4 files changed

+5
-7
lines changed

trio_asyncio/__init__.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,9 +61,7 @@
6161
issue=64,
6262
instead="an import from the top-level trio_asyncio package",
6363
)
64-
for name in (
65-
"adapter", "async_", "base", "child", "handles", "loop", "sync", "util"
66-
)
64+
for name in ("adapter", "async_", "base", "child", "handles", "loop", "sync", "util")
6765
}
6866

6967
# Provide aliases in the old place for names that moved between modules.

trio_asyncio/_adapter.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -189,9 +189,9 @@ def trio_as_aio(proc, *, loop=None):
189189

190190
trio_as_asyncio = trio_as_aio
191191

192-
193192
_shim_running = ContextVar("shim_running", default=False)
194193

194+
195195
@types.coroutine
196196
def _allow_asyncio(fn, *args):
197197
shim = _shim_running

trio_asyncio/_deprecate.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -109,9 +109,7 @@ def __getattr__(self, name):
109109
if instead is DeprecatedAttribute._not_set:
110110
instead = info.value
111111
thing = "{}.{}".format(self.__name__, name)
112-
warn_deprecated(
113-
thing, info.version, issue=info.issue, instead=instead
114-
)
112+
warn_deprecated(thing, info.version, issue=info.issue, instead=instead)
115113
return info.value
116114

117115
raise AttributeError(name)

trio_asyncio/_loop.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -414,6 +414,7 @@ async def _run_task(proc, args):
414414

415415
# Non-deprecated aliases for event loop methods
416416

417+
417418
def _running_loop():
418419
loop = current_loop.get()
419420
if loop is None:
@@ -465,6 +466,7 @@ def run_trio_task(proc, *args):
465466
# code. Therefore, we "chase the pointer" and inline the body of the
466467
# deprecated loop method into each of these functions.
467468

469+
468470
@deprecated("0.10.0", issue=38, instead="aio_as_trio(proc(*args))")
469471
def wrap_generator(proc, *args):
470472
return run_aio_generator(_running_loop(), proc(*args))

0 commit comments

Comments
 (0)