admin管理员组

文章数量:1532473

Traceback (most recent call last):
  File "G:\PycharmProjects\quantaxis\venv\Scripts\quantaxis_webserver-script.py", line 33, in <module>
    sys.exit(load_entry_point('quantaxis-webserver', 'console_scripts', 'quantaxis_webserver')())
  File "g:\pycharmprojects\quantaxis\quantaxis_webserver-master\QAWebServer\QA_Web.py", line 158, in main
    start_server(handlers, address, port)
  File "g:\pycharmprojects\quantaxis\quantaxis_webserver-master\QAWebServer\QA_Web.py", line 176, in start_server
    http_server.start(1)
  File "g:\pycharmprojects\quantaxis\venv\lib\site-packages\tornado\tcpserver.py", line 222, in start
    self.add_sockets(sockets)
  File "g:\pycharmprojects\quantaxis\venv\lib\site-packages\tornado\tcpserver.py", line 157, in add_sockets
    self._handlers[sock.fileno()] = add_accept_handler(
  File "g:\pycharmprojects\quantaxis\venv\lib\site-packages\tornado\netutil.py", line 268, in add_accept_handler
    io_loop.add_handler(sock, accept_handler, IOLoop.READ)
  File "g:\pycharmprojects\quantaxis\venv\lib\site-packages\tornado\platform\asyncio.py", line 79, in add_handler
    self.asyncio_loop.add_reader(
  File "C:\Users\h\AppData\Local\Programs\Python\Python38\lib\asyncio\events.py", line 501, in add_reader
    raise NotImplementedError
NotImplementedError

找到这个项目使用的python环境的lib\site-packages,做下面的修改,在path-to-python\lib\site-packages\tornado\platform\asyncio.py开头添加代码:
 

import sys

if sys.platform == 'win32':
  asyncio.set_event_loop_policy(asyncio.WindowsSelectorEventLoopPolicy())

参考了jb51,行星带 老兄的分享,感谢

本文标签: 错误项目tornadoNotImplementedError