mirror of
https://github.com/janeczku/calibre-web
synced 2024-12-26 01:50:31 +00:00
Fix #1180 working on windows with tornado and python <3.8 again
This commit is contained in:
parent
6698773d81
commit
2535bbbcf1
@ -146,7 +146,7 @@ class WebServer(object):
|
|||||||
self.unix_socket_file = None
|
self.unix_socket_file = None
|
||||||
|
|
||||||
def _start_tornado(self):
|
def _start_tornado(self):
|
||||||
if os.name == 'nt':
|
if os.name == 'nt' and sys.version_info > (3, 7):
|
||||||
import asyncio
|
import asyncio
|
||||||
asyncio.set_event_loop_policy(asyncio.WindowsSelectorEventLoopPolicy())
|
asyncio.set_event_loop_policy(asyncio.WindowsSelectorEventLoopPolicy())
|
||||||
log.info('Starting Tornado server on %s', _readable_listen_address(self.listen_address, self.listen_port))
|
log.info('Starting Tornado server on %s', _readable_listen_address(self.listen_address, self.listen_port))
|
||||||
|
Loading…
Reference in New Issue
Block a user