Always use libev if possible
This commit is contained in:
parent
eb63eb7b1d
commit
51f49cd45a
1 changed files with 6 additions and 0 deletions
|
@ -12,6 +12,12 @@ def startupError(msg):
|
||||||
|
|
||||||
# Third party modules
|
# Third party modules
|
||||||
import gevent
|
import gevent
|
||||||
|
try:
|
||||||
|
# Workaround for random crash when libuv used with threads
|
||||||
|
if "libev" not in str(gevent.config.loop):
|
||||||
|
gevent.config.loop = "libev-cext"
|
||||||
|
except Exception as err:
|
||||||
|
startupError("Unable to switch gevent loop to libev: %s" % err)
|
||||||
|
|
||||||
import gevent.monkey
|
import gevent.monkey
|
||||||
gevent.monkey.patch_all(thread=False, subprocess=False)
|
gevent.monkey.patch_all(thread=False, subprocess=False)
|
||||||
|
|
Loading…
Reference in a new issue