return channel object for communicating with the asynchronously
executing 'source' code which will have a corresponding 'channel'
object in its executing namespace.
def remote_exec(self, source, stdout=None, stderr=None):
origin: Gateway
where:
function source:
def remote_exec(self, source, stdout=None, stderr=None):
""" return channel object for communicating with the asynchronously
executing 'source' code which will have a corresponding 'channel'
object in its executing namespace.
"""
try:
source = str(Source(source))
except NameError:
try:
import py
source = str(py.code.Source(source))
except ImportError:
pass
channel = self.newchannel()
outid = self._newredirectchannelid(stdout)
errid = self._newredirectchannelid(stderr)
self._outgoing.put(Message.CHANNEL_OPEN(channel.id,
(source, outid, errid)))
return channel
called in /home/johnny/projects/merlinux/py/dist/py/test/rsession/rsync.py
traceback execnet.SshGateway.remote_exec.0
called in /home/johnny/projects/merlinux/py/dist/py/test/rsession/master.py