(self)
Downloads the archive from one of the mirrors
Downloads the archive from one of the mirrors
Downloads the archive from one of the mirrors
def download(self):
        """Downloads the archive from one of the mirrors"""
        if not os.path.exists(self.archive_path):
            for turn in range(self.trials_404):
                for i, link in enumerate(self.download_links()):
                    try:
                        return self.do_download(link, self.archive_path)
                    except HTTPError as e:
                        if e.code != 404:
                            raise
                        print("HTTP 404 while trying to get the archive using link" \
                              " '%s' (trial %d/%d)" % (link, turn+1, self.trials_404))
                    except URLError as e:
                        print("Error while trying to get the archive using link" \
                              " '%s' (trial %d/%d)" % (link, turn+1, self.trials_404))
                        raise e
def download ( self ) : if not os . path . exists ( self . archive_path ) : for turn in range ( self . trials_404 ) : for i , link in enumerate ( self . download_links ( ) ) : try : return self . do_download ( link , self . archive_path ) except HTTPError as e : if e . code != 404 : raise print ( "HTTP 404 while trying to get the archive using link" " '%s' (trial %d/%d)" % ( link , turn + 1 , self . trials_404 ) ) except URLError as e : print ( "Error while trying to get the archive using link" " '%s' (trial %d/%d)" % ( link , turn + 1 , self . trials_404 ) ) raise e