question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

GallerySaver.saveImage crashes on Android 11.0

See original GitHub issue

Devices: Pixel 4 XL, Pixel 5 XL Device Type: Virtual & Physical Android Version: 11.0 API 30

An exception and crash occurs upon calling GallerySaver.saveImage however, the image DOES get saved to the gallery successfully. The app simply crashes at this point. Tested also on Android 10.0 on both devices and the crash does not happen.

E/AndroidRuntime(20767): java.lang.IllegalArgumentException: Invalid column NULL E/AndroidRuntime(20767): at android.database.DatabaseUtils.readExceptionFromParcel(DatabaseUtils.java:172) E/AndroidRuntime(20767): at android.database.DatabaseUtils.readExceptionWithFileNotFoundExceptionFromParcel(DatabaseUtils.java:153) E/AndroidRuntime(20767): at android.content.ContentProviderProxy.openAssetFile(ContentProviderNative.java:704) E/AndroidRuntime(20767): at android.content.ContentResolver.openAssetFileDescriptor(ContentResolver.java:1816) E/AndroidRuntime(20767): at android.content.ContentResolver.openOutputStream(ContentResolver.java:1518) E/AndroidRuntime(20767): at android.content.ContentResolver.openOutputStream(ContentResolver.java:1494) E/AndroidRuntime(20767): at carnegietechnologies.gallery_saver.FileUtils.storeThumbnail(FileUtils.kt:172) E/AndroidRuntime(20767): at carnegietechnologies.gallery_saver.FileUtils.insertImage(FileUtils.kt:84) E/AndroidRuntime(20767): at carnegietechnologies.gallery_saver.GallerySaver$saveMediaFile$1$success$1.invokeSuspend(GallerySaver.kt:69) E/AndroidRuntime(20767): at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33) E/AndroidRuntime(20767): at kotlinx.coroutines.DispatchedTask.run(Dispatched.kt:238) E/AndroidRuntime(20767): at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.kt:594) E/AndroidRuntime(20767): at kotlinx.coroutines.scheduling.CoroutineScheduler.access$runSafely(CoroutineScheduler.kt:60) E/AndroidRuntime(20767): at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(CoroutineScheduler.kt:742)

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:16 (1 by maintainers)

github_iconTop GitHub Comments

5reactions
dancamdevcommented, Jan 9, 2021

It probably isn’t, I came up with my own solution, I’ll share as an article or package, I’m not sure yet 🙌

0reactions
hbendevcommented, Sep 13, 2021

Any updates on this?

Starting in November 2021, app updates will be required to target API level 30 or above

As stated on https://developer.android.com/

Read more comments on GitHub >

github_iconTop Results From Across the Web

Flutter app crashes when trying to download multiple network ...
seems that package does not support multiple concurrent downloads - instead try for (final imageUrl in selectedImages) { await GallerySaver.
Read more >
gallery_saver | Flutter Package - Pub.dev
Saves images and videos from network or temporary file to external storage. Both images and videos will be visible in Android Gallery and...
Read more >
Photo capture crash on Android 11 - Google Groups
Hello,. While trying to capture an image app crashes and doesn't produce the image. Issue is similar to this, but while testing on...
Read more >
'Save Image' crashes Firefox - Mozilla Support
Hi, Until recently the right click, 'save image as' method of saving a site image has worked flawlessly, now it goes into a...
Read more >
How to resolve application crash while saving images to ...
When you try to save image in device's gallery by using image editor, ... To resolve application crash in Android, you should grant...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found