[3D models][Download] Catch Easy EDA errors
- Print an error and continue Fixes #515
This commit is contained in:
parent
76f168fb45
commit
a98b46195c
|
|
@ -233,7 +233,11 @@ class Base3DOptions(VariantOptions):
|
||||||
logger.debug('Using cached model `{}`'.format(cache_name))
|
logger.debug('Using cached model `{}`'.format(cache_name))
|
||||||
return cache_name
|
return cache_name
|
||||||
logger.debug('- Trying to download {} component as {}/{}'.format(lcsc_id, self._tmp_dir, fname))
|
logger.debug('- Trying to download {} component as {}/{}'.format(lcsc_id, self._tmp_dir, fname))
|
||||||
replace = download_easyeda_3d_model(lcsc_id, self._tmp_dir, fname)
|
try:
|
||||||
|
replace = download_easyeda_3d_model(lcsc_id, self._tmp_dir, fname)
|
||||||
|
except Exception as e:
|
||||||
|
logger.error(f'Error downloading 3D model for LCSC part {lcsc_id} (model: {model} problem: {e})')
|
||||||
|
replace = None
|
||||||
if not replace:
|
if not replace:
|
||||||
return None
|
return None
|
||||||
# Successfully downloaded
|
# Successfully downloaded
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue