Is there an existing issue for this?
Use case
I'm using source: ImageSource.gallery for users to select images, in which case users can accidentally select video files instead of images. If that happens, Flutter will return the following exception but it is not catchable by the Image Picker package. Therefore, my app will try to load invalid data and crashes. Please add a function to catch whatever error raised by Flutter in the package so the app will know if a valid image data is loaded.
D/skia (28235): --- Failed to create image decoder with message 'unimplemented'
I posted the same question here.
https://stackoverflow.com/questions/76419277/in-flutter-how-do-i-check-that-an-image-returns-from-image-picker-is-valid?noredirect=1#comment134757812_76419277
Proposal
Modify the package so that the exception from underline Flutter will be caught at package level.
Is there an existing issue for this?
Use case
I'm using
source: ImageSource.galleryfor users to select images, in which case users can accidentally select video files instead of images. If that happens, Flutter will return the following exception but it is not catchable by the Image Picker package. Therefore, my app will try to load invalid data and crashes. Please add a function to catch whatever error raised by Flutter in the package so the app will know if a valid image data is loaded.D/skia (28235): --- Failed to create image decoder with message 'unimplemented'I posted the same question here.
https://stackoverflow.com/questions/76419277/in-flutter-how-do-i-check-that-an-image-returns-from-image-picker-is-valid?noredirect=1#comment134757812_76419277
Proposal
Modify the package so that the exception from underline Flutter will be caught at package level.