From 1f533ed31e9eb615a73b50f9eedb2345467230e1 Mon Sep 17 00:00:00 2001 From: yairzori-guardicore <84378648+yairzori-guardicore@users.noreply.github.com> Date: Tue, 26 Mar 2024 23:22:39 +0000 Subject: [PATCH 1/2] support pyhthon3.12 --- haigha2/transports/gevent_transport.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/haigha2/transports/gevent_transport.py b/haigha2/transports/gevent_transport.py index e3260a3..bdebab2 100644 --- a/haigha2/transports/gevent_transport.py +++ b/haigha2/transports/gevent_transport.py @@ -11,7 +11,7 @@ try: import gevent import gevent.ssl - import gevent._socket2 + import gevent._socket3 import gevent.socket import gevent.ssl from gevent.event import Event From 26e5ad662dc05c2b10eeaf04349083169094caa0 Mon Sep 17 00:00:00 2001 From: yairzori-guardicore <84378648+yairzori-guardicore@users.noreply.github.com> Date: Tue, 26 Mar 2024 23:27:47 +0000 Subject: [PATCH 2/2] Support Python3.12 and python 2.7 --- haigha2/transports/gevent_transport.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/haigha2/transports/gevent_transport.py b/haigha2/transports/gevent_transport.py index bdebab2..1653303 100644 --- a/haigha2/transports/gevent_transport.py +++ b/haigha2/transports/gevent_transport.py @@ -11,7 +11,10 @@ try: import gevent import gevent.ssl - import gevent._socket3 + try: + import gevent._socket2 + except ImportError: + import gevent._socket3 import gevent.socket import gevent.ssl from gevent.event import Event