Remove old gevent compatibility patches

This commit is contained in:
shortcutme 2019-03-16 02:05:27 +01:00
parent 95cf47d9a4
commit 91c5556f21
No known key found for this signature in database
GPG Key ID: 5B63BAE6CB9613AE
1 changed files with 2 additions and 10 deletions

View File

@ -8,16 +8,8 @@ import logging
# Third party modules
import gevent
from gevent import monkey
if "patch_subprocess" in dir(monkey): # New gevent
monkey.patch_all(thread=False, subprocess=False)
else: # Old gevent
import ssl
# Fix PROTOCOL_SSLv3 not defined
if "PROTOCOL_SSLv3" not in dir(ssl):
ssl.PROTOCOL_SSLv3 = ssl.PROTOCOL_SSLv23
monkey.patch_all(thread=False)
# Not thread: pyfilesystem and systray icon, Not subprocess: Gevent 1.1+
import gevent.monkey
gevent.monkey.patch_all(thread=False, subprocess=False)
update_after_shutdown = False # If set True then update and restart zeronet after main loop ended
restart_after_shutdown = False # If set True then restart zeronet after main loop ended