Skip to content

client: send connecting state - #27

Merged
iFixRobots merged 1 commit into
mautrix:mainfrom
iFixRobots:iFixRobots/desk-31282-gvoice-retry
Sep 25, 2026
Merged

iFixRobots merged 1 commit into
mautrix:mainfrom
iFixRobots:iFixRobots/desk-31282-gvoice-retry

Conversation

@iFixRobots

@iFixRobots iFixRobots commented Sep 25, 2026 •

Copy link
Copy Markdown
Contributor

A local Google Voice connection can fail while fetching the account, for example when the network temporarily cannot reach Google. The client logs Failed to get account on connect and sends UNKNOWN_ERROR with the request error. When BridgeV2 is configured to reconnect after that error, it tries again later, but if the second failure has the same error text, BridgeV2 deduplicates the state before scheduling another attempt. The account remains disconnected even if the network returns afterward.

I found this by tracing the account-fetch failure through GVClient.Connect and BridgeV2's state queue. Connect currently sends no state between attempts, so the second UNKNOWN_ERROR can be identical to the first. Now it sends CONNECTING as an attempt starts. If that attempt fails, its UNKNOWN_ERROR is a new transition and BridgeV2 can schedule the next reconnect; if it succeeds, normal connection reporting takes over. Bad credentials still take their existing path. This works with a host that enables BridgeV2's unknown-error reconnect policy; that configuration is a separate SDK change.

@iFixRobots
iFixRobots requested a review from tulir September 25, 2026 13:30
@tulir tulir changed the title Reset Google Voice state before reconnect attempts client: send connecting state Sep 25, 2026
@iFixRobots
iFixRobots merged commit 3986acf into mautrix:main Sep 25, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants