add support for python3 for gevent backend