call site 0 for execnet.Channel.isclosed
execnet/testing/test_rsync.py - line 48
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
   def test_dirsync(self):
       dest = self.dest1
       dest2 = self.dest2
       source = self.source
   
       for s in ('content1', 'content2-a-bit-longer'): 
           source.ensure('subdir', 'file1').write(s) 
           rsync = RSync(self.source)
           rsync.add_target(gw, dest)
           rsync.add_target(gw2, dest2)
           rsync.send()
           assert dest.join('subdir').check(dir=1)
           assert dest.join('subdir', 'file1').check(file=1)
           assert dest.join('subdir', 'file1').read() == s 
           assert dest2.join('subdir').check(dir=1)
           assert dest2.join('subdir', 'file1').check(file=1)
           assert dest2.join('subdir', 'file1').read() == s 
           
       source.join('subdir').remove('file1')
       rsync = RSync(source)
->     rsync.add_target(gw2, dest2)
       rsync.add_target(gw, dest)
       rsync.send()
       assert dest.join('subdir', 'file1').check(file=1)
       assert dest2.join('subdir', 'file1').check(file=1)
       rsync = RSync(source)
       rsync.add_target(gw, dest, delete=True)
       rsync.add_target(gw2, dest2)
       rsync.send()
       assert not dest.join('subdir', 'file1').check() 
       assert dest2.join('subdir', 'file1').check() 
execnet/rsync.py - line 143
131
132
133
134
135
136
137
138
139
140
141
142
143
144
   def add_target(self, gateway, destdir, 
                  finishedcallback=None, **options):
       """ Adds a remote target specified via a 'gateway'
               and a remote destination directory. 
           """
       assert finishedcallback is None or callable(finishedcallback)
       for name in options:
           assert name in ('delete',)
       def itemcallback(req):
           self._receivequeue.put((channel, req))
       channel = gateway.remote_exec(REMOTE_SOURCE)
       channel.setcallback(itemcallback, endmarker = None)
->     channel.send((str(destdir), options))
       self._channels[channel] = finishedcallback
execnet/channel.py - line 154
149
150
151
152
153
154
155
156
157
158
159
160
   def send(self, item):
       """sends the given item to the other side of the channel,
           possibly blocking if the sender queue is full.
           Note that an item needs to be marshallable.
           """
->     if self.isclosed(): 
           raise IOError, "cannot send to %r" %(self,) 
       if isinstance(item, Channel):
           data = Message.CHANNEL_NEW(self.id, item.id)
       else:
           data = Message.CHANNEL_DATA(self.id, item)
       self.gateway._outgoing.put(data)