Skip to content

Commit 5cfe634

Browse files
remote/client: use non-deprecated iscoroutinefunction from inspect module
asyncio.iscoroutinefunction() is deprecated [1] since Python 3.14 [2]. Use inspect.iscoroutinefunction() instead. [1] https://docs.python.org/3/deprecations/index.html#pending-removal-in-python-3-16 [2] python/cpython@bc9d92c Signed-off-by: Bastian Krause <bst@pengutronix.de>
1 parent 9709747 commit 5cfe634

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

labgrid/remote/client.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1759,6 +1759,8 @@ def __str__(self):
17591759

17601760

17611761
def main():
1762+
import inspect
1763+
17621764
basicConfig(
17631765
level=logging.WARNING,
17641766
stream=sys.stderr,
@@ -2214,7 +2216,7 @@ def main():
22142216
logging.debug("Started session")
22152217

22162218
try:
2217-
if asyncio.iscoroutinefunction(args.func):
2219+
if inspect.iscoroutinefunction(args.func):
22182220
if getattr(args.func, "needs_target", False):
22192221
place = session.get_acquired_place()
22202222
target = session._get_target(place)

0 commit comments

Comments
 (0)