Bug 429406 - Gmail auth token is not remembered across restarts
Summary: Gmail auth token is not remembered across restarts
Status: RESOLVED FIXED
Alias: None
Product: libkgapi
Classification: Frameworks and Libraries
Component: General (show other bugs)
Version: 5.15.80
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Daniel Vrátil
URL:
Keywords:
: 430887 431055 431584 (view as bug list)
Depends on:
Blocks:
 
Reported: 2020-11-20 17:40 UTC by Antonio Rojas
Modified: 2022-07-09 09:04 UTC (History)
16 users (show)

See Also:
Latest Commit:
Version Fixed In: 5.16.2


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Antonio Rojas 2020-11-20 17:40:58 UTC
SUMMARY
Since updating to 20.12 beta, gmail accounts need to be reauthenticated after every akonadi restart.

STEPS TO REPRODUCE
1. Set up a gmail account
2. akonadictl restart

OBSERVED RESULT

the Google authentication dialog pops up

EXPECTED RESULT

auth token is remembered.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 5.20.3 
KDE Frameworks Version: 5.76.0
Qt Version: 5.15.2
Comment 1 Txutxifel 2020-12-07 14:39:24 UTC
Same here,

Opensue Leap 15.2, with 20.12 beta.
Comment 2 Antonio Rojas 2020-12-20 09:40:42 UTC
Downgrading libkgapi to 20.08.3 fixes the issue
Comment 3 Frank Noack 2020-12-23 11:32:08 UTC
libkgapi-20.12.0-r1 did not solve the problem here.
Comment 4 Domenico Panella 2020-12-28 07:55:13 UTC
Same here.

Operating System: Void Linux
KDE Plasma Version: 5.20.4
KDE Frameworks Version: 5.77.0
Qt Version: 5.15.2
Kernel Version: 5.9.16_1
OS Type: 64-bit
Comment 5 Domenico Panella 2020-12-28 07:56:01 UTC
libkgapi-20.12.0_1
Comment 6 Antonio Rojas 2020-12-28 10:30:43 UTC
*** Bug 430887 has been marked as a duplicate of this bug. ***
Comment 7 Colin J Thomson 2020-12-30 20:43:16 UTC
I just found some more info on this which might apply to #428762 also.

https://invent.kde.org/pim/libkgapi/-/merge_requests/12
Comment 8 Colin J Thomson 2021-01-02 10:38:03 UTC
*** Bug 431055 has been marked as a duplicate of this bug. ***
Comment 9 Unknown 2021-01-03 10:52:09 UTC
@ Antonio Rojas 2020-12-20 09:40:42 UTC
Downgrading libkgapi to 20.08.3 fixes the issue

thank you that helped, error is gone.
So I won't be doing any more updates now.
You always have problems with PIM.
Comment 10 Antonio Rojas 2021-01-06 11:02:43 UTC
I narrowed this down to https://invent.kde.org/pim/libkgapi/-/commit/6fa8198750e7624bd7be643c8a8c428dc58a1d6d

Reverted that commit and didn't get any authentication prompts for over 24 hours. Went back to 20.12.0 and I'm getting prompts every few hours again.
Comment 11 Bug Janitor Service 2021-01-06 14:57:39 UTC
A possibly relevant merge request was started @ https://invent.kde.org/pim/libkgapi/-/merge_requests/17
Comment 12 ml 2021-01-06 19:17:00 UTC
(In reply to Bug Janitor Service from comment #11)
> A possibly relevant merge request was started @
> https://invent.kde.org/pim/libkgapi/-/merge_requests/17
This patch fully resolves issue for me, no more annoying google auth popups every hour.
Comment 13 Domenico Panella 2021-01-07 09:44:42 UTC
Just applied this patch and it works for me.
https://invent.kde.org/pim/libkgapi/-/merge_requests/17
Comment 14 Colin Griffith 2021-01-11 15:59:04 UTC
(In reply to Antonio Rojas from comment #10)
> I narrowed this down to
> https://invent.kde.org/pim/libkgapi/-/commit/
> 6fa8198750e7624bd7be643c8a8c428dc58a1d6d
> 
> Reverted that commit and didn't get any authentication prompts for over 24
> hours. Went back to 20.12.0 and I'm getting prompts every few hours again.

Thank you so much for fixing this! However, the page with your fix says it can't be merged without a rebase, or something like that.

This bug has been irritating me a lot, and I don't have the hard drive space to compile things myself. Would really appreciate this getting merged and a new release coming out with the fix.
Comment 15 Antonio Rojas 2021-01-13 22:56:42 UTC
Git commit d81d247026ac993ac5717ca471c7fcf1778951f2 by Antonio Rojas.
Committed on 13/01/2021 at 20:40.
Pushed by arojas into branch 'release/20.12'.

Don't reset account scopes if not necessary

This triggers unnecesary authentication prompts

M  +3    -1    src/core/accountmanager.cpp

https://invent.kde.org/pim/libkgapi/commit/d81d247026ac993ac5717ca471c7fcf1778951f2
Comment 16 Antonio Rojas 2021-01-14 08:41:21 UTC
*** Bug 431584 has been marked as a duplicate of this bug. ***
Comment 17 Domenico Panella 2021-01-14 15:46:10 UTC
I applied that patch but every machine reboot, akonadi requires google authentication via web browser. 
I don't know if is linked at this bug.
Comment 18 Colin J Thomson 2021-02-09 16:13:56 UTC
Updated to 20.12.2 and that has fixed it for me. Even after restarts there are no more authentication pop ups, Thank you.