LibreNews-Android icon indicating copy to clipboard operation
LibreNews-Android copied to clipboard

Unable to load flashes from storage

Open ghost opened this issue 7 years ago • 22 comments

hello I have a Samsung Galaxy A3 2016 with android Nougat 7.0 . After activating the debug option, I got these notifications : Performing asynchronous flash retieval... Flash found 22 Retrieving flash from https://librenews.io/api?latest=-1 unable to load flashes from storage :/data/user/0/app.librenews.io.librenews/files/flashes.json (no such file or directory)

ghost avatar Aug 23 '17 09:08 ghost

I'm getting the same error on Lineage OS 14 (which corresponds to 7.1.1 Android).

knezi avatar Sep 21 '17 04:09 knezi

Do your operating systems have any special permissions for file handling? The way that LibreNews handles files is relatively standard and consistent with the Android API's best practices.

I do hope I can figure out a fix for this issue soon, as it seems to be affecting a not-insignificant number of users...

milesmcc avatar Sep 21 '17 14:09 milesmcc

Do your operating systems have any special permissions for file handling? The way that LibreNews handles files is relatively standard and consistent with the Android API's best practices.

As far as I know, it does not. It is just a fresh installation of LOS.

/data/user/0/ is a symlink to /data/data, the file does not exist nonetheless. Moreover, other applications seem to have some data in .../app/files/, so it should be fine and the code really uses the path specified by API...

Is it confirmd that it works on Noughat?

EDIT: find / -name flashes.json did not return any results.

knezi avatar Sep 25 '17 07:09 knezi

I have a similar problem, but it is most likely due to the fact that I freshly installed LibreNews and simply don't have any flashes saved yet. It also always throws an error when trying to receive flashes. The logcat contains a lot of SSL errors. Did you by any chance recently change something with the server certificate?

flocke avatar Dec 27 '17 16:12 flocke

Hi @flocke, turns out that the renewed SSL certificate wasn't loaded by nginx on the server last night. Your issue should be fixed now, let me know if it isn't.

milesmcc avatar Dec 27 '17 17:12 milesmcc

@milesmcc You are right, just hit "Refresh" and now everything is working. Thanks for the quick fix!

flocke avatar Dec 27 '17 17:12 flocke

Hi, I have the exact same issue on my clean install of LineageOS. How am I supposed to fix it ?

I tried reinstalling LibreNews to no avail...

thiswillbeyourgithub avatar Mar 12 '18 18:03 thiswillbeyourgithub

Hi @thiswillbeyourgithub — could you take a screenshot of the permissions page? It's possible that this issue is caused by your OS automatically denying LibreNews the necessary permissions.

milesmcc avatar Mar 12 '18 19:03 milesmcc

@milesmcc the "permission" field is greyed out with a message stating that no permission is asked. The screenshot is in a foreign language so I think it's enough to tell you this :)

thiswillbeyourgithub avatar Mar 12 '18 20:03 thiswillbeyourgithub

Yeah, LibreNews doesn't ask for any permissions.

flocke avatar Mar 12 '18 21:03 flocke

@thiswillbeyourgithub when you installed, were you prompted by your app store application to grant LibreNews any permissions? When I install, I get a little notice from F-Droid that LibreNews requests access to internal storage and the network. Do you experience this?

Note: this is F-Droid/Play Store functionality, not LibreNews; LibreNews' permissions are hard-coded into its manifest.

milesmcc avatar Mar 13 '18 00:03 milesmcc

@milesmcc I installed it using FDroid but just tested using the playstore and had the same issue.

FDroid's app info says that it has the rights to launch at startup, to access network and complete network access but you have access to this information too ^^

The installation prompt says librenews doesn't require any specific permissions.

And when launching librenews I was not asked for any permissions via the little floating prompt.

So to answer your question, no I don't get asked for access to internal storage.

thiswillbeyourgithub avatar Mar 13 '18 08:03 thiswillbeyourgithub

It is currently working for me, I don't know what changed and I don't think it's on my side.

thiswillbeyourgithub avatar Apr 20 '18 17:04 thiswillbeyourgithub

@thiswillbeyourgithub perhaps your device updated?

milesmcc avatar Apr 20 '18 22:04 milesmcc

@milesmcc What update do you mean ? I regularly update my Lineage OS (snapshots) and F-Droid says you haven't had an update in 6 months or so, so I don't think that's related. I thought this was more of a server issue. But oh well.

thiswillbeyourgithub avatar Apr 21 '18 08:04 thiswillbeyourgithub

Having this same issue. I have a Samsung J3 for info. Not using Lineage OS either.

Niquarl avatar Aug 13 '18 05:08 Niquarl

@Niquarl what happens if you uninstall and reinstall the app? Does the app have all the permissions it asks for?

I haven't been able to reproduce this error on my end, so I'm still grasping at straws here...

milesmcc avatar Aug 13 '18 14:08 milesmcc

I have tried to uninstall and reinstall severall times. I wanted to try installing via the Google Play Store to see if it made a difference.

I believe that it gets access to all the permissions it asks for though I don't think it is asking for storage access.

Tried the two public servers available on the github.

Not really sure what is wrong with it. With my old phone the app worked wonderfully but now it doesn't. It seems to be able to access the api and the flashes as when I "debug" the app it can fetch 21 or22 of them

If you have any questions or wish that i share any screenshot do not hesitate to ask. Thanks.

Edit: I do not have an SD card btw if that changes something, i think i use to with the od phone ^^.

Niquarl avatar Aug 16 '18 03:08 Niquarl

@thiswillbeyourgithub I tried to install it again and now it works (even though it took two days to start receiving news - it always said no new news found). So I guess something in LOS has been resolved.

knezi avatar Aug 22 '18 07:08 knezi

@knezi I'm glad that the issue is resolved for you. I just did a few server upgrades because it was having trouble handling the load—hopefully the news should be pushed more immediately now. :slightly_smiling_face:

milesmcc avatar Aug 22 '18 16:08 milesmcc

Glad it has apparently been resolved then. I'll try to download anew the app though as I said in a previous message I do not use Lineage OS. I'll get back to you if I can get some news.

Niquarl avatar Aug 29 '18 19:08 Niquarl

So, I have tried it again for about a week. Didn't work, not one notification. When I installed it didn't actually ask me for storage permission though.

Edit: Also I do not seem to be able to find any librenews files on my phone.

Jusy like the first comment I have a 'no file exists'

Niquarl avatar Oct 07 '18 03:10 Niquarl