-
Notifications
You must be signed in to change notification settings - Fork 113
Unable to create compressed file in Android Oreo (8.0) #42
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
I see a fix here, but its still not working for me. Please update if you see fix in this. https://stackoverflow.com/questions/46489706/android-oreo-api-26-create-dir-in-external-storage |
I have the same issue on my Samsung S9 Oreo 8.0.0 |
hrm... I will try to find out more... I tried it on a android 9 device and it works without problems... maybe the problems are just appear in 8? |
May be.. I don't have android 9 so didn't checked. |
I will check different android versions later the day. |
thank you.
Let me know if you need any, I can provide sample apk.
…On Wed, Jun 13, 2018 at 11:59 AM JoschkaSchulz ***@***.***> wrote:
I will check different android versions later the day.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#42 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AC4yyapRB1Ly2Bi6mD8xE7IRjBepxTckks5t8LFSgaJpZM4UYsC4>
.
|
Same here, 8.1. I've never worked with native Android code but it looks like folder.mkdir(); must be failing, then you don't check the result of saveFile (which is null after mkdir fails). Something to do with permissions? |
@JoschkaSchulz Any updates? @crawft Permissions are looking good. |
I have debugged the code and its failing to create folder at line no#115: success = folder.mkdir(). So saveFile function is returning null and scaledFile.toString() is failing at line no#61. I have tested line no#110 as follows, but still same error.
I have following permissions: preference name="AndroidPersistentFileLocation" value="Internal" Please let me know if I am missing anything. |
I worked around this by changing the code around line 129 as follows, this creates the resized image in a private folder so may not work if you want the image elsewhere (though maybe you could just copy it after or something).
|
@crawft would you be so kind to create a pull request? then we could fix that for everyone :) |
I used the method that @crawft had given and created a PR for it. |
any news on this Topic ? the branch was merged in 2018 and this issue isn't closed. |
Uh oh!
There was an error while loading. Please reload this page.
Hi,
This plugin is working as a charm but suddenly it stopped working, we found that its working well till till Android 7.0 but not in Android Oreo 8.0.
We are getting "Attempt to invoke virtual method 'java.lang.String android.net.Uri.toString()' on a null object reference".
I see that its not able to create folder and compressed file in given folder.
Please let us know if you found any work around for Android 8.0.
thank you
The text was updated successfully, but these errors were encountered: