mvysny / photocloud-frame-slideshow

Android Digital Photo Frame
https://www.android-photo-frame.eu
14 stars 1 forks source link

App Stopping everysingle time I click on the browse button to select the source of my photos [$50 awarded] #94

Closed ChezThomas closed 5 years ago

ChezThomas commented 5 years ago

Using an android tablet (Android version 4.4.2) as a photoframe (Paid Version), when we click on Browse (to point at the folder location), it systematically give us the "Unfortunately, Photocloud Slideshow has stopped" message. It does that on Gallery, and I also tried on the DropBox and it gives me the same problem. I suspect and authorisation problem ? But would wait for your reply and suggestions first. I tried reinstalling it several times, and also factory resetting the tablet, but the problem remains. Any idea on a potential solution ? Thanks in advance, T.

--- The **[$50 bounty](https://www.bountysource.com/issues/61062366-app-stopping-everysingle-time-i-click-on-the-browse-button-to-select-the-source-of-my-photos?utm_campaign=plugin&utm_content=tracker%2F53303527&utm_medium=issues&utm_source=github)** on this issue has been claimed at [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F53303527&utm_medium=issues&utm_source=github).
mvysny commented 5 years ago

Hi Thomas, thanks for letting me know! I haven't received any crash report, but I suspect that the crash is because of the new permission system. I have done a couple of fixes in this regard, and I will push the update to see whether the condition improves. Please let me know whether the update fixed anything.

ChezThomas commented 5 years ago

Thanks for your quick reply! Any ETA for this new update ? Cheers. T

ChezThomas commented 5 years ago

Or is there any way to revert to an older version (At least to try to see if it fixes my problem) ? As few months ago it used to work perfectly.

mvysny commented 5 years ago

Hmm, I'm not sure there is a way to revert to the older version. I mean, I have both the older 1.11.6 and the newest 1.13 published and available on Google Play, but I'm not sure whether Google Play allows you to pick version to be installed... Anyway 1.13 is out, please wait a bit until Google Play updates the app on your phone.

mvysny commented 5 years ago

And hey, many thanks for the bounty, highly appreciated! :+1:

ChezThomas commented 5 years ago

More than welcome ;-) Hope it will help to keep you motivated on continuing improving this simple but very useful app 👍

ChezThomas commented 5 years ago

So I just check with the newly pushed version 1.13 and the problem remains. I still get the "Unfortunatly Photocloud Slideshow has stopped" as soon as I try to click the BROWSER button or SLIDESHOW... Any idea on what I can do ? Or any chance to give you a remote access to it ideally ?

mvysny commented 5 years ago

The device should report the crash automatically and I should receive a mail about a crash, but I guess we can't expect reliability from Android...

Is this happening only for one particular Slideshow type? For example does this happen only for the Local Gallery? Perhaps you can try to review and grant permissions in your phone. What version of Android do you have please? In the worst case would you be interested in attaching the device to your computer via a USB cable and downloading logs from the device? That would provide lots of insight into the nature of the crash... You can follow this guide: http://aedict.eu/faq.html "Aedict 3 log" - the tutorial applies to any Android app really.

ChezThomas commented 5 years ago

I tried following the guide, but since I am on Mac, it's a different software and quite lost with it :-) screen shot 2018-07-19 at 5 33 12 pm (Android Studio). Also I tried just now to submit the log report from the android tablet directlty, so not sure you received the email (should be from an email address starting with velxxxxxx...@gmail.com screen shot 2018-07-19 at 5 38 34 pm

Lastly not sure I am doing anything wrong in my Android settings. but I attached some photos for you to have a look.

Thanks a lot in advance.

screen shot 2018-07-19 at 5 40 48 pm screen shot 2018-07-19 at 5 40 41 pm screen shot 2018-07-19 at 5 41 53 pm

mvysny commented 5 years ago

Hey thanks! Actually reporting the crash to Google helped, I have one crash reported from a device Hisense Sero8 (rk3188) - would that happen to be yours? Of course retarded Google Play console hides the actual error message. I hate Android and its ecosystem.

mvysny commented 5 years ago

The exception is as follows:

Caused by: java.io.IOException: 
  at sk.baka.android.spi.AndroidFS.check (AndroidFS.java:91)
  at sk.baka.android.spi.AndroidFS.mkdir (AndroidFS.java:137)
  at sk.baka.android.DirUtils.mkdir (DirUtils.java:58)
  at sk.baka.android.DirUtils.mkdirs (DirUtils.java:95)
  at sk.baka.photoframe.fs.FileCache.get (FileCache.java:59)

It seems that PhotoCloud no longer can create folders on Android 4.4. Let me test this in an emulator.

BTW do you see that missing message? It was supposed to say "Can't create directory /foo because of 0x12 permission denied" but Google thoughtfully filtered it out because of privacy reasons. Schmmaaaart Google. Morons.

mvysny commented 5 years ago

Okay I've pushed another release 1.13.1, blind-fixing the issue. Please try it out and let me know whether it helped

ChezThomas commented 5 years ago

It works with the latest update :-) Thanks again! T.

mvysny commented 5 years ago

Awesome, I'm happy that it works for you! The problem was the missing permission WRITE_EXTERNAL_STORAGE. Even though the Android API documentation explicitly says it's not needed for Android 4.4 and higher to access app's cached files, on your Android 4.4 device the permission is needed. This is the Android fragmentation in all of its ugliness :( Anyways, I'm happy that you can continue to use the app.

mvysny commented 5 years ago

ps: the Crashlytics report finally arrived after a day's delay :-D It was as we suspected - PhotoCloud was unable to create the tmp_cache folder because of missing WRITE_EXTERNAL_STORAGE permission that shouldn't have been necessary in the first place.

Caused by java.lang.RuntimeException: java.io.IOException: Failed to create directory '/mnt/internal_sd/Android/data/sk.baka.photoframe/cache/tmp_cache_5be18553ab2343edaece03a0d68ed933thumbnail': #13 Permission denied (cache:0775:drwxrwxr-x)
       at sk.baka.photoframe.fs.FileCache.get(FileCache.java:61)
       at sk.baka.photoframe.fsimpl.cache.ThumbnailCache.<init>(ThumbnailCache.java:53)
       at sk.baka.photoframe.stream.StreamSource.newFileSystem(StreamSource.kt:216)
       at sk.baka.photoframe.stream.StreamSource.newFileSystem$default(StreamSource.kt:203)
       at sk.baka.photoframe.frame.PhotoIterator.createIterator(PhotoIterator.kt:66)
       at sk.baka.photoframe.frame.PhotoIterator.createIterator(PhotoIterator.kt:32)