Repository navigation
login: don't report dropped connections as login timeouts - #1087
Open
iFixRobots wants to merge 2 commits into
Open
iFixRobots wants to merge 2 commits into
iFixRobots wants to merge 2 commits into
Conversation
Contributor
|
No issues found.
All required CI checks passed on
Select any unchecked box below to run or rerun that agent. Full resultsIndent Review Agent
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Every
events.Disconnectedduring login was reported asFI.MAU.WHATSAPP.LOGIN_TIMEOUT. On phones that drop sockets of backgrounded apps, the connection often dies a few seconds after the pairing code or QR is shown, and the user is told they ran out of time.WhatsApp closes the login socket after the QR refs run out: a fresh client that never pairs gets
<xmlstreamend/>about 210s after the refs arrive. SinceDisconnectedcarries no reason, this uses the existinggetQRIndex()schedule. A disconnect while QR codes are still valid now returnsFI.MAU.WHATSAPP.LOGIN_DISCONNECTED("Connection to WhatsApp was interrupted while waiting for login. Please try again."). Anything after that stays a timeout. The log line now includes the time since the first QR.Before / after, against the real WhatsApp server with the TCP socket closed mid-login:
LOGIN_TIMEOUTLOGIN_DISCONNECTEDLOGIN_TIMEOUTLOGIN_DISCONNECTEDLOGIN_TIMEOUTLOGIN_TIMEOUTLOGIN_TIMEOUTLOGIN_TIMEOUTLinear: https://linear.app/beeper/issue/PLAT-41010
Tag
@indentto continue the conversation here.