1
0
mirror of https://github.com/GNS3/gns3-server synced 2025-01-24 06:51:19 +00:00

Merge pull request #1204 from GNS3/loop-speed-on-win

Disable loop debug on default
This commit is contained in:
Jeremy Grossmann 2017-10-27 16:43:54 +07:00 committed by GitHub
commit 2c0804d4ee

View File

@ -36,7 +36,6 @@ from ..compute.port_manager import PortManager
from ..compute.qemu import Qemu from ..compute.qemu import Qemu
from ..controller import Controller from ..controller import Controller
# do not delete this import # do not delete this import
import gns3server.handlers import gns3server.handlers
@ -234,8 +233,11 @@ class WebServer:
ssl_context = self._create_ssl_context(server_config) ssl_context = self._create_ssl_context(server_config)
self._loop = asyncio.get_event_loop() self._loop = asyncio.get_event_loop()
# Asyncio will raise error if coroutine is not called
self._loop.set_debug(True) if log.getEffectiveLevel() == logging.DEBUG:
# On debug version we enable info that
# coroutine is not called in a way await/yield from
self._loop.set_debug(True)
for key, val in os.environ.items(): for key, val in os.environ.items():
log.debug("ENV %s=%s", key, val) log.debug("ENV %s=%s", key, val)