def get_proxy( self ): # get passphrase here, not in __init__, because it is not needed # on remote task hosts if 'ssh messaging = True' (otherwise, if # it is needed, we will end up in this method). self.pphrase = passphrase( self.suite, self.owner, self.host ).get( None, None ) import cylc_pyro_client return cylc_pyro_client.client( self.suite, self.pphrase, self.owner, self.host, self.try_timeout, self.port ).get_proxy( self.task_id )
def get_proxy( self ): # get passphrase here, not in __init__, because it is not needed # on remote task hosts if 'ssh messaging = True' (otherwise, if # it is needed, we will end up in this method). self.pphrase = passphrase( self.suite, self.owner, self.host, verbose=self.verbose ).get( None, None ) # this raises an exception on failure to connect: import cylc_pyro_client return cylc_pyro_client.client( self.suite, self.pphrase, self.owner, self.host, self.pyro_timeout, self.port, self.verbose ).get_proxy( self.task_id )
def get_proxy(self): # get passphrase here, not in __init__, because it is not needed # on remote task hosts if 'ssh messaging = True' (otherwise, if # it is needed, we will end up in this method). self.pphrase = passphrase(self.suite, self.owner, self.host).get(None, None) import cylc_pyro_client return cylc_pyro_client.client(self.suite, self.pphrase, self.owner, self.host, self.try_timeout, self.port).get_proxy(self.task_id)
def __init__( self, suite, owner, host, pphrase, pyro_timeout, verbose, debug ): from cylc_pyro_client import client compat.__init__( self, suite, None, verbose, debug ) try: proxy = client( self.suite, pphrase, owner, host, pyro_timeout ).get_proxy( 'remote' ) self.required_version = proxy.get_cylc_version() except Exception, x: if debug: raise raise SystemExit(x)