def checkSettings(self): """ Check the sanity of the settings in this object. This method is called after all calls to parseSetting(...) have been done. Any defaults may be set here as well. An Exception is raised in the case of insanity. """ client.checkSettings(self)
def checkSettings(self): """ Check the sanity of the settings in this object. This method is called after all calls to parseSetting(...) have been done. Any defaults may be set here as well. An Exception is raised in the case of insanity. """ client.checkSettings(self) if not self.port: raise Exception( "The port parameter is required for host {0}".format( self.name ) )
def checkSettings(self): """ Check the sanity of the settings in this object. This method is called after all calls to parseSetting(...) have been done. Any defaults may be set here as well. An Exception is raised in the case of insanity. """ if self.source or self.builder: raise Exception( "client:libtorrent only supports remotely available prebuilt clients. This is to prevent compilation/compatibility hell." ) client.checkSettings(self) if not self.isRemote: raise Exception( "client:libtorrent requires itself to be a remotely available prebuilt client." )
def checkSettings(self): """ Check the sanity of the settings in this object. This method is called after all calls to parseSetting(...) have been done. Any defaults may be set here as well. An Exception is raised in the case of insanity. """ client.checkSettings(self) if not self.port: self.port = 3000 elif self.port < 1024: Campaign.logger.log( "Using a privileged port for host {0} is not recommended: {1}.".format( self.name, self.port ) )
def checkSettings(self): """ Check the sanity of the settings in this object. This method is called after all calls to parseSetting(...) have been done. Any defaults may be set here as well. An Exception is raised in the case of insanity. """ client.checkSettings(self) if self.listenPort: if self.listenAddress: self.listenAddress = "{0}:{1}".format( self.listenAddress, self.listenPort ) else: self.listenAddress = ":{0}".format( self.listenPort ) if self.chunkSize is None: self.chunkSize = 1024
def checkSettings(self): """ Check the sanity of the settings in this object. This method is called after all calls to parseSetting(...) have been done. Any defaults may be set here as well. An Exception is raised in the case of insanity. """ client.checkSettings(self) if self.builder: raise Exception( "client:utorrent does not support compilation from source... Where did you get those sources, anyway?" ) if self.useWine: if not os.path.exists( os.path.join( Campaign.testEnvDir, 'ClientWrappers', 'utorrent', 'ut_server_logging.py' ) ) or not os.path.exists( os.path.join( Campaign.testEnvDir, 'ClientWrappers', 'utorrent', 'settings.dat' ) ): raise Exception( "The uTorrent client runner, when using wine, needs the utorrent runner script (ut_server_logging.py) and the prepared windows settings file (settings.dat). These are expected to be present in ClientWrappers/utorrent/, but they aren't." ) else: if not os.path.exists( os.path.join( Campaign.testEnvDir, 'ClientWrappers', 'utorrent', 'ut_server_logging.py' ) ): raise Exception( "The uTorrent client runner needs the utorrent runner script (ut_server_logging.py). This is expected to be present in ClientWrappers/utorrent/, but it isn't." )