def _install(quidditch, retries=5):
 passed = False
 clean = True
 comment = ''
 while (not passed):
  log.debug('download_collection is this long: {0}'.format(str(quidditch.install_collection.Count)))
  log.debug('Installing. tries left: {0}'.format(str(retries)))
  passed = quidditch.Install()
  log.info('Done installing: {0}'.format(str(passed)))
  if isinstance(passed, Exception):
   clean = False
   comment += 'Failed while trying to install the updates.\n DCTB  DCTB {0}\n'.format(str(passed))
   retries -= 1
   if retries:
    comment += '{0} tries to go. retrying\n'.format(str(retries))
    passed = False
   else:
    comment += 'out of retries. this update round failed.\n'
    return (comment, False, retries)
 if clean:
  comment += 'Install was done without error.\n'
 return (comment, True, retries)

def _install ( quidditch , retries = 5 ) : passed = False clean = True comment = '' while ( not passed ) : log . debug ( 'download_collection is this long: {0}' . format ( str ( quidditch . install_collection . Count ) ) ) log . debug ( 'Installing. tries left: {0}' . format ( str ( retries ) ) ) passed = quidditch . Install ( ) log . info ( 'Done installing: {0}' . format ( str ( passed ) ) ) if isinstance ( passed , Exception ) : clean = False comment += 'Failed while trying to install the updates.\n DCTB  DCTB {0}\n' . format ( str ( passed ) ) retries -= 1 if retries : comment += '{0} tries to go. retrying\n' . format ( str ( retries ) ) passed = False else : comment += 'out of retries. this update round failed.\n' return ( comment , False , retries ) if clean : comment += 'Install was done without error.\n' return ( comment , True , retries )
determine whether salt-minion is installed and .