def DoRarExtraction(rarArchive, targetFile, dstDir):
  """
  RAR extraction with exception catching

  Parameters
  ----------
    rarArchive : RarFile object
      RarFile object to extract.

    targetFile : string
      Target file name.

    dstDir : string
      Target directory.

  Returns
  ----------
    boolean
      False if rar extraction failed, otherwise True.
  """
  try:
    rarArchive.extract(targetFile, dstDir)
  except BaseException as ex:
    goodlogging.Log.Info("EXTRACT", "Extract failed - Exception: {0}".format(ex))
    return False
  else:
    return True
RAR extraction with exception catching

  Parameters
  ----------
    rarArchive : RarFile object
      RarFile object to extract.

    targetFile : string
      Target file name.

    dstDir : string
      Target directory.

  Returns
  ----------
    boolean
      False if rar extraction failed, otherwise True.