@@ -90,7 +90,7 @@ def __init__(self, back_plane_ip_address=None, subscriber_port='43125',
9090 self .receive_loop_idle_addition = receive_loop_idle_addition
9191 self .connect_time = connect_time
9292 self .subscriber_list = subscriber_list
93- self .context = None
93+ self .my_context = None
9494 self .subscriber = None
9595 self .publisher = None
9696 self .the_task = None
@@ -152,14 +152,14 @@ def __init__(self, back_plane_ip_address=None, subscriber_port='43125',
152152 # noinspection PyUnresolvedReferences
153153 async def begin (self ):
154154 # establish the zeromq sub and pub sockets and connect to the backplane
155- if not self .context :
156- self .context = zmq .asyncio .Context ()
155+ if not self .my_context :
156+ self .my_context = zmq .asyncio .Context ()
157157 # noinspection PyUnresolvedReferences
158- self .subscriber = self .context .socket (zmq .SUB )
158+ self .subscriber = self .my_context .socket (zmq .SUB )
159159 connect_string = "tcp://" + self .back_plane_ip_address + ':' + self .subscriber_port
160160 self .subscriber .connect (connect_string )
161161
162- self .publisher = self .context .socket (zmq .PUB )
162+ self .publisher = self .my_context .socket (zmq .PUB )
163163 connect_string = "tcp://" + self .back_plane_ip_address + ':' + self .publisher_port
164164 self .publisher .connect (connect_string )
165165
@@ -275,4 +275,4 @@ async def clean_up(self):
275275 """
276276 await self .publisher .close ()
277277 await self .subscriber .close ()
278- await self .context .term ()
278+ await self .my_context .term ()
0 commit comments