laforge has submitted this change. ( https://gerrit.osmocom.org/c/python/osmo-python-tests/+/34406?usp=email )
Change subject: tests/test_py3: fix deprecated loop arg ......................................................................
tests/test_py3: fix deprecated loop arg
The loop arg has been removed in python 3.10. The same event loop will be used without passing the argument, so it can be removed.
Fix for: TypeError: gather() got an unexpected keyword argument 'loop'
Related: https://stackoverflow.com/a/60315290 Related: https://docs.python.org/3/library/asyncio-task.html#asyncio.gather Change-Id: I776bc463246e7a1a9adbb7c06012353d65694507 --- M tests/test_py3.py 1 file changed, 18 insertions(+), 1 deletion(-)
Approvals: laforge: Looks good to me, approved pespin: Looks good to me, but someone else must approve Jenkins Builder: Verified
diff --git a/tests/test_py3.py b/tests/test_py3.py index 0d526a9..710dcb8 100644 --- a/tests/test_py3.py +++ b/tests/test_py3.py @@ -46,7 +46,7 @@ print('Serving on {}...'.format(server.sockets[0].getsockname()))
# Async client running in the subprocess plugged to the same event loop - loop.run_until_complete(asyncio.gather(asyncio.create_subprocess_exec('./scripts/osmo_ctrl.py', '-g', 'mnc', '-d', test_host, '-p', test_port), loop = loop)) + loop.run_until_complete(asyncio.gather(asyncio.create_subprocess_exec('./scripts/osmo_ctrl.py', '-g', 'mnc', '-d', test_host, '-p', test_port)))
loop.run_forever()