Widget not updating on Android 9

As a pixel 2 user I can confirm the widget (lack of) update bug and (the bigger issue) the widget refresh button failure… Which seems to be after 2min as @Kevin says. My previous workaround was to launch the app (to load it’s 50-120 items) then exit (even before they all loaded) and “successfully” use the widget refresh button, which would then trigger the Android Flowx notification of it’s update (an notification icon); which works! Currently, I’ve turned off battery optimization for Flowx and this seems to have resolved the “widget refresh button” issue, as a brief flash of an Android notification is always triggered (unlike before and after 2min? passed.) It’s to soon to tell if removing battery optimization for the app resolves the lack of widget updates, and if, I notice increase battery drain. I’ll track both and update here; but for now, this seems to have resolved the “biggest” bug, the widget refresh button failure. Perhaps, Android 9 battery optimization is blocking the widget refresh button call or it’s background data call? The lack of an Android notification “icon” showing after 2min(?) when Flowx “battery optimized” is enabled, seems like a significant clue. Also, “battery optimized” is a learned state which evolves over time (I understand), which likely explains the diversity of bug descriptions over time. I personally had my Flowx widget updating fine for about a week (last week) when previously it had not for some time before. I could report that 3.096 broke it “again”, but more likely than not, either my usage of Flowx increased for that week (it had) or Android was recompiling it’s “battery optimization” (because of a prior app update?). In the end, if you’re going to have a widget refresh button, I would prefer to have it work even with “battery optimization” on… After 2min. I do love battery optimization.

1 Like

Android 9 “Battery Optimization” disabled for the Flowx app 100% resolved: lack of auto widget updates, lack of widget “refresh button” functionality (after 2min?), and (consistently) large item count (100+) downloads each time Flowx was opened. This was tested for 5 days with 3.096 and 2 days with 3.102 on a Pixel 2. Negligible battery impact, meaning I can’t tell the difference.

I recommend this Android 9 setting update for Flowx widget users.

1 Like

Thanks @FlowxLloyd. This might have to be the solution for a while since I haven’t started rewriting the widget. As someone said, it’s not the most fun job. But it is on the list and something I want to do.

2 Likes

This isn’t over yet with the 3.112 version.
I purposely refreshed the widget and later it still didn’t update at a later time.
Deleted all widgets and made new ones; those all update regularly…

1 Like

Hi @Windsailor, I totally agree. This was never meant to be the fix.

I get emails now and then about widgets not updating. This is just a quick method to check the status so users on Android 9 are notified about the optimization and can turn it off before emailing me.

Note, this is still a problem with Pixel phones running Android 9+. Seldomly other phones.

The issue is prioritizing rewriting the widget update method vs other features like radar. Widget updates is working for most users. Only a handful of users on Pixel phone will be happy if I fix the widget updates, but thousands of users will be happy if I add radar.

Cheers, Duane.

2 Likes

@Windsailor, are you on Android 9 or Android 10? I am still wondering if it’s fixed on Android 10. I find it odd you can turn of battery optimizations on other phones running Android 9+ and the widget work, but this is not the case on Pixel phone. You have to admit this is odd and seems like a bug on Pixel phones.

1 Like

Android 9, June 5th security patch. Pixel 2 XL.
Haven’t ran the 10 beta yet. Everytime I run the beta I have to do a factory reset to opt out of it. Easy to do but a pain to get everything back.
Not exactly sure what is causing this or how to fix it on this end…
Try \ Catch. ?

1 Like

Wish I could get an updated device I’m still running Android 6 :joy::joy::joy: less bugs but also less memory so it runs out of room quickly and will be a dinosaur soon

@Windsailor, no, don’t do a Android 10 update. It was only if you were running it. I want to find someone running it to see if it was a bug and Google fixed it.

A “try/catch” isn’t even close. I set the update period (30 minutes) in the widget.xml file the Android OS uses but the Android OS doesn’t even call Flowx for an update. It’s not a crash or anything, it’s just that the OS is ignoring the XML file and the battery optimization state.

1 Like

I’ve been thinking about a Pixel 3 as my next upgrade. This might not happen until the end of the year but if I do, it’s more likely to get fix.

1 Like

It’s not a big thing.
I’ve seen other issues with other apps that are similar in nature - like a Car Dock. Click on a link in one app and another app opened up, not supposed to happen. It’s was like Android cached too much memory on a stack and the wrong thing was pulled up. Memory management - not releasing the stack? Garbage collection issues? That could have been a bunch of things. Factory reset did the trick though. And things are getting better. I do run a lot of apps, 123+ and counting.
I did have my finger on the beta button - haven’t pushed it yet. Doing a factory reset every now and then does work wonders in cleaning things up…

1 Like

If you got a feeling in your bones that something big is going down, you’d be right. I’ve been walking the dark woods of widgets for days now. I’ve read many a pages, tried many codes, fought many bugs - day and night - and I think I have broken its back. I can see the light at the tree line.

Thanks for the 6 months of patience. It should be in beta in the next few days. Hopefully this will make things right.

Cheers, Duane.

2 Likes

Yay, version 3.208 is in beta with the new automatic widget update process.

Try it out and watch that it’s updating every 30 minutes.

If you see issues, go into the settings and turn on “Foreground Widget Updates”.

If you want bonus points, reset the battery optimization settings for Flowx in the Android settings, then monitor the widget updates.

Please let me know how you go over the next few days, whether positive or negative. I’d really like to know before releasing to productions.

I really hope this is the solution and thanks for your super patience.

Cheers, Duane.

2 Likes

@duane just fyi I have graduated to android 9 :joy::joy:

1 Like