thunderbird / thunderbird-android

K-9 Mail – Open Source Email App for Android
https://k9mail.app/
Apache License 2.0
9.97k stars 2.47k forks source link

Folder polling is not reliable any more #7839

Open cremor opened 3 months ago

cremor commented 3 months ago

Checklist

App version

6.803

Where did you get the app from?

Google Play

Android version

14

Device model

Pixel 7a

Steps to reproduce

  1. Configure the app to poll for new emails every 15 minutes.
  2. Turn off the phone screen and do not use the phone.
  3. Send yourself an email from another device.
  4. Wait for the notification.

Expected behavior

Notifications for new emails should be shown not more than 15 minutes later.

Actual behavior

No notifications for new emails are shown. As far I can tell it's not just that the notification is missing, but the app doesn't even poll for emails.

Sometimes I get the emails when I wake up the phone (turn the screen on). Sometimes I need to unlock the phone to get them. Sometimes I even need to open the app. In those cases I see that no new emails are shown, then the progress indicator line on top of the email list shows up, and only then the emails are polled.

This problem started a few weeks ago. Maybe with the update to version 6.802. Maybe it was also an Android update (e.g. April or May update) that caused it.

The Android setting/permission for battery usage of the app is already set to "allow background usage" and "not limited" (my translations, I'm not sure on the official english wording of those settings).

Logs

No response

anon1892 commented 3 months ago

I don't know if this is related, but folder syncing seems unreliable too : I've deleted a lot of emails from Thunderbird (Linux), changes appears on the email provider web interface, but I still see deleted emails on K9 (Android 13, v6.803, F-Droid)...

Xavron commented 2 months ago

There's actually a lot of possibilities here and some are device.

Its difficult to say what the app can or can't do in being exact and there will be cases where it may not be possible. Conversely, Google won't really allow this to happen to their own app which is another thing entirely lol.

But, all 3rd party developer Android apps are going through this. Some get by better but many see this type of problem.

cremor commented 2 months ago
  • Android 14 for instance also has a separated location of sleeping and deep sleeping apps. The issue post here doesn't specify.

Where can I find both of those settings?

  • The email service that is used may timeout or have other connection issues or limits causing it to not be on exact time or not happen.

I use 3 email addresses of 2 different providers (one is Gmail). All show the same problem.

Xavron commented 2 months ago

The Android 14 new feature should be in Android Settings > Battery > Background usage limits > sleeping / deep sleeping apps. Android 14 will auto add apps as time goes by. If its the one you were talking about then not allowing it in there is a good idea as it definitely can and will break apps.

cremor commented 2 months ago

I don't have such an menu entry in the battery settings. I've also looked through all sub-menus and could only find the app specific settings which are already set to unrestricted background usage.