Skip to content

gmail/oauth fails with maxconnections > 1 in v8.0.3 #250

Description

@agoldst

I upgraded offlineimap from v8.0.1 to v8.0.3 and was no longer able to sync with my gmail.com e-mail. It would fail with an authentication failure error (imap: Socket dead after XOAUTH2 failure, aborting remaining auth methods). I had maxconnections = 2 but when I change it to maxconnections = 1 (or run offlineimap with -d imap logging) it succeeds. I am able to separately get refresh and access tokens using an independent program (whhich is called via oauth2_refresh_token_eval for offlineimap).

Maybe it's kind of race condition somewhere when two threads try to do OAuth at the same time? I wonder if it has something to do with the change in #244 ? I don't know enough to trace exactly what's happening, but perhaps the answer will be obvious to the maintainers.

This is offlineimap 8.0.3, imaplib2 v3.06, Python v3.14.5, OpenSSL 3.6.2 7 Apr 2026; macOS 26.5, M1 MacBook Pro.

And thank you for this wonderful program.

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingtestingIssue included in branch "testing"

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions