When an account's token is expired, account-polld should stop polling that account and show notification to refresh account.

Bug #1470132 reported by Ratchanan Srirattanamet
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
account-polld (Ubuntu)
New
Undecided
Unassigned

Bug Description

When a token of an account (e.g. Google account) expires, it causes account-polld to print these messages repeatedly:

2015/06/28 20:55:35 New account data for existing account with id 3
2015/06/28 20:55:35 Starting poll for account 3
2015/06/28 20:55:35 Polling account 3
2015/06/28 20:55:35 Error while polling 3: Token expired
2015/06/28 20:55:35 Poll for account 3 has failed: Token expired
2015/06/28 20:55:35 Ending poll for account 3

It also caused CPU usage to go up to about 20%. That means account-polld is probably polling the account repeatedly. So, account-polld should stop polling that account and show notification to refresh that account.

From IRC irc.freenode.net #ubuntu-touch:
dobey: account-polld should probably create a notification for those cases that tells you what token is expired and give you a way to open accounts and log in again
dobey: and should probably flag an invalid token as invalid and ignore it until it's refreshed or whatever

Ubuntu touch willy. Image version 240.
Device: LG L90 Dual (I'm doing a port)

Revision history for this message
Niklas Wenzel (nikwen) wrote :

Normally, it should refresh its token after that. Doesn't it do that for you?

Revision history for this message
Ratchanan Srirattanamet (peat-new) wrote :

I don't know. That just appeared repeatedly with about a second apart. Unfortunately, the issue isn't currently happening, and I've lost the original log file. So, you probably have to wait until the problem occurs again. Sorry about that.

Revision history for this message
Niklas Wenzel (nikwen) wrote :

Thank you for your reply. It might be that this happens when one changes his Gmail password. Is that what you did?

Revision history for this message
Cédric Bellegarde (gnumdk) wrote :

No password change here... Same bug.

2015/08/27 22:28:53 Poll for account 4 has failed: Token expired
2015/08/27 22:28:53 Ending poll for account 4
2015/08/27 22:28:53 New account data for existing account with id 4
2015/08/27 22:28:53 Starting poll for account 4
2015/08/27 22:28:53 Polling account 4
2015/08/27 22:28:53 Error while polling 4: Token expired
2015/08/27 22:28:53 Poll for account 4 has failed: Token expired
2015/08/27 22:28:53 Ending poll for account 4
2015/08/27 22:28:53 New account data for existing account with id 4
2015/08/27 22:28:53 Starting poll for account 4
2015/08/27 22:28:53 Polling account 4
2015/08/27 22:28:54 Error while polling 4: Token expired
2015/08/27 22:28:54 Poll for account 4 has failed: Token expired
2015/08/27 22:28:54 Ending poll for account 4
2015/08/27 22:28:54 New account data for existing account with id 4
2015/08/27 22:28:54 Starting poll for account 4
2015/08/27 22:28:54 Polling account 4
2015/08/27 22:28:54 Error while polling 4: Token expired
2015/08/27 22:28:54 Poll for account 4 has failed: Token expired
2015/08/27 22:28:54 Ending poll for account 4
2015/08/27 22:28:54 New account data for existing account with id 4
2015/08/27 22:28:54 Starting poll for account 4
2015/08/27 22:28:54 Polling account 4
2015/08/27 22:28:55 Error while polling 4: Token expired
2015/08/27 22:28:55 Poll for account 4 has failed: Token expired
2015/08/27 22:28:55 Ending poll for account 4
2015/08/27 22:28:55 New account data for existing account with id 4
2015/08/27 22:28:55 Starting poll for account 4
2015/08/27 22:28:55 Polling account 4

This kill the phone battery is one hour on an MX4.

Revision history for this message
Cédric Bellegarde (gnumdk) wrote :

Can't find a way to renew the token from the UI

Revision history for this message
Niklas Wenzel (nikwen) wrote :

Oh, that's a bad one!

Do you know what kind of account account 4 is? Is it a Gmail one?

Revision history for this message
Niklas Wenzel (nikwen) wrote :

And would you mind uploading the whole log file?

Revision history for this message
Cédric Bellegarde (gnumdk) wrote :

Twitter account.
Was not expired as twitter app was working.

Removing/adding account fix the isssue

No log file :(

Revision history for this message
Niklas Wenzel (nikwen) wrote :

Well, there is a difference between the token and your password.

The token is sent to your phone when your login credentials are sent to the server for the first time. That way the phone does not always have to send your full login credentials to the server and can use the token instead. In order to not make that token something one can use to login to your account forever, it expires at some point. That's what happened.
Then for some reason it failed to get a new one.

> No log file :(

Would you mind explaining why you don't want to upload the log file? There's no personal information in there besides that you own a twitter account (and maybe a Gmail or Facebook one) and we won't be able to find out your username. The only thing we will be able to see is at which time a notification was displayed to you (not their content).
We really need one if we want to fix this.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.