call site 2 for execnet.Channel.setcallback
execnet/testing/test_gateway.py - line 242
234
235
236
237
238
239
240
241
242
243
244
   def test_waiting_for_callbacks(self):
       l = []
       def callback(msg):
           import time; time.sleep(0.2)
           l.append(msg)
       channel = self.gw.remote_exec(source='''
               channel.send(42)
               ''')
->     channel.setcallback(callback)
       channel.waitclose(TESTTIMEOUT) 
       assert l == [42]