[Possibly regression?] geary no longer succeeds in fetching mail due to "GoaError 4" (gnome-online-accounts error?)
(This is a forward to upsteam from https://gitlab.com/postmarketOS/pmaports/-/issues/1577 )
Describe your issue
geary no longer succeeds in fetching mail due to GoaError 4 (gnome-online-accounts error?). It worked at the very least on June 12th (since that is the latest e-mail that still shows up in my inbox) and broke afterward, my best guess is due to some update to either gnome-online-accounts or geary. I attached a log below of the geary error report which has a problem backtrace.
What's the expected behavior?
geary works
What's the current behavior?
geary no longer works, always gives "GoaError 4". Also see error report below
How to reproduce your issue?
Not sure! The error just began occurring around the switch from postmarketOS 21.12 to 21.06, which is where they switched to latest Alpine I believe. The gnome online account I use is a Google account, only mail is enabled (gmail), and the login method is OAuth2 since Google recently blocked other login methods. Thunderbird on my laptop uses OAuth2 as well to retrieve mails from the very same mail account/inbox and there it just works fine. Since some sort of keyring issue is mentioned, I installed seahorse and could access the keyring just fine as well (on the PinePhone where geary broke). Also, gnome-calendar on that phone still works where I use a CalDAV nextcloud remote calendar which to my knowledge also saves its login data in the keyring. So the keyring doesn't seem to be generally broken, or not entirely at least.
More info
Geary Problem Report (with backtrace):