Fix Issue #124 by spawning the connection handler gevent process after the DSN socket is created and the object is connected to the DSN. Prior to this bug fix, users receive an error stating that "class does not have attribute '_socket'" when an SLE object is instantiated but not immediately connected to the DSN (i.e. .connect() is not run immediately after instantiating the object). This is due to the connection handler function, which sends heartbeats to the DSN, being spawned as a gevent process in __init__.
Fix Issue #124 by spawning the connection handler gevent process after the DSN socket is created and the object is connected to the DSN. Prior to this bug fix, users receive an error stating that "
class does not have attribute '_socket'
" when an SLE object is instantiated but not immediately connected to the DSN (i.e..connect()
is not run immediately after instantiating the object). This is due to the connection handler function, which sends heartbeats to the DSN, being spawned as a gevent process in__init__
.