mirror of
https://github.com/PaddlePaddle/FastDeploy.git
synced 2026-04-24 01:29:57 +08:00
[BugFix][Optimization] Replace silent failures with catchable exceptions and informative error messages (#6533)
* init * init * fix format * add * add files * add ut * fix some * add ut * add more * add * fix pre-commit * fix pre-commit * fix cover * skip long seq * add * add * fix * remove not need * fix set attr * fix comments * fix comments * fix failed tests --------- Co-authored-by: gongweibao <gognweibao@baidu.com>
This commit is contained in:
@@ -42,7 +42,7 @@ def process_transparency(image):
|
||||
if _is_transparent(image): # Check and fix transparent images
|
||||
data_processor_logger.info("Image has transparent background, adding white background.")
|
||||
image = _convert_transparent_paste(image)
|
||||
except:
|
||||
pass
|
||||
except Exception as e:
|
||||
data_processor_logger.warning(f"Failed to process image transparency: {e}")
|
||||
|
||||
return ImageOps.exif_transpose(image)
|
||||
|
||||
Reference in New Issue
Block a user