Auth: Return recovery PendingIntent for modern clients - #3788
Open
Noir-Lime wants to merge 1 commit into
Open
Conversation
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.
Summary
Return
userRecoveryPendingIntentalongside the existinguserRecoveryIntentwhen token retrieval requires user permission. Reuse the same immutable PendingIntent for the auth notification. Older clients still receive the original Intent.Client behavior
Google's
com.google.android.gms:play-services-auth-base:18.3.0client reads both bundle keys. ItsgetTokenWithDetailserror handling logs the following when the advertised GmsCore version is at least233800000and the PendingIntent is missing:This threshold is observable in the client implementation, not a claim about public API documentation. The client still constructs a legacy recovery exception if only the Intent is present; this patch supplies the modern recovery payload too.
Artifact: https://dl.google.com/dl/android/maven2/com/google/android/gms/play-services-auth-base/18.3.0/play-services-auth-base-18.3.0.aar
Verification
git diff --checkpasses.:play-services-core:assembleDefaultRelease -Pabi=arm64-v8a.Originally proposed in MorpheApp#249; submitting upstream at the downstream maintainer's request. That PR remains open.