@@ -1324,7 +1324,6 @@ def load_nursery(
13241324 path = config .ART_DATA_PATH ,
13251325 extract = False ,
13261326 url = [
1327- "https://archive.ics.uci.edu/ml/machine-learning-databases/nursery/nursery.data" ,
13281327 "https://www.dropbox.com/s/l24hwvkuueor6lp/nursery.data?dl=1" ,
13291328 ],
13301329 )
@@ -1509,7 +1508,6 @@ def get_file(
15091508
15101509 if download :
15111510 logger .info ("Downloading data from %s" , url )
1512- error_msg = "URL fetch failure on {}: {} -- {}"
15131511 try :
15141512 for url_i in url_list :
15151513 try :
@@ -1545,13 +1543,9 @@ def progress_bar(blocks: int = 1, block_size: int = 1, total_size: Optional[int]
15451543 urlretrieve (url_i , full_path )
15461544
15471545 except HTTPError as exception : # pragma: no cover
1548- raise Exception (
1549- error_msg .format (url_i , exception .code , exception .msg ) # type: ignore
1550- ) from HTTPError # type: ignore
1546+ logger .error (url_i , exception )
15511547 except URLError as exception : # pragma: no cover
1552- raise Exception (
1553- error_msg .format (url_i , exception .errno , exception .reason ) # type: ignore
1554- ) from HTTPError # type: ignore
1548+ logger .error (url_i , exception )
15551549 except (Exception , KeyboardInterrupt ): # pragma: no cover
15561550 if os .path .exists (full_path ):
15571551 os .remove (full_path )
0 commit comments