Open Und3r1ine opened 2 years ago
server.py:17: DeprecationWarning: "@coroutine" decorator is deprecated since Python 3.8, use "async def" instead def accept_server(server_reader, server_writer): server.py:21: DeprecationWarning: "@coroutine" decorator is deprecated since Python 3.8, use "async def" instead def process_fileread(server_reader, server_writer,filename): server.py:63: DeprecationWarning: "@coroutine" decorator is deprecated since Python 3.8, use "async def" instead def handle_server(server_reader, server_writer):
师傅 你这个问题解决了吗
使用 async def 代替 @asyncio.coroutine 来定义协程,使用 await 代替 yield from 来异步等待。可以解决这个问题
修改支持python3.8+:https://github.com/clown1ay/MySQL_Fake_Server/blob/master/server.py
server.py:17: DeprecationWarning: "@coroutine" decorator is deprecated since Python 3.8, use "async def" instead def accept_server(server_reader, server_writer): server.py:21: DeprecationWarning: "@coroutine" decorator is deprecated since Python 3.8, use "async def" instead def process_fileread(server_reader, server_writer,filename): server.py:63: DeprecationWarning: "@coroutine" decorator is deprecated since Python 3.8, use "async def" instead def handle_server(server_reader, server_writer):