Skip to content

PoToken: Optimize po-token refresh logic#2894

Merged
mar-v-in merged 3 commits intomicrog:masterfrom
DaVinci9196:potoken_refresh
Jul 11, 2025
Merged

PoToken: Optimize po-token refresh logic#2894
mar-v-in merged 3 commits intomicrog:masterfrom
DaVinci9196:potoken_refresh

Conversation

@DaVinci9196
Copy link
Copy Markdown
Contributor

Solve the problem that the locally cached token is invalid and cannot be regenerated, causing YouTube playback to freeze.

@ILoveOpenSourceApplications
Copy link
Copy Markdown

ILoveOpenSourceApplications commented May 6, 2025

Will this resolve #2831, #2789, #2354, #2352 & #2103?

@DaVinci9196
Copy link
Copy Markdown
Contributor Author

Will this resolve #2831, #2789, #2354 & #2103?

Maybe, this pr is a refresh strategy, if the token is detected to be invalid, it will be regenerated and returned

@mar-v-in mar-v-in added the 🔒 Integrity Play Integrity, SafetyNet, DroidGuard and ReCAPTCHA label May 14, 2025
@leo20481141
Copy link
Copy Markdown

leo20481141 commented May 18, 2025

I'm not sure if this will help and if this keeps happenning to other people but I fixed this issue #2789 by dointg this.

I did a factory reset and installed the new version of microG, but I made sure to set device registration profile to real this time (it's important to do it before enabling device registration for the first time because after that the id was already generated and before adding your google account) and to enable allow apps to find accounts before adding my google account.

I don't know why it happened before and if it was fixed in the new version or if it happens only if you set it up in some other way (maybe adding the google account through an app or before enabling device registration or leaving device registration profile in native) but now it works fine.

@mar-v-in mar-v-in added this to the 0.3.9 milestone Jun 11, 2025
@mar-v-in mar-v-in merged commit 4a2978d into microg:master Jul 11, 2025
1 check passed
@DaVinci9196 DaVinci9196 deleted the potoken_refresh branch July 14, 2025 01:58
DaVinci9196 added a commit to DaVinci9196/GmsCore that referenced this pull request Jul 17, 2025
@ILoveOpenSourceApplications
Copy link
Copy Markdown

@DaVinci9196, The issue isn’t that the access token needs refreshing. The issue is that the locally cached PoToken is invalid and must be regenerated — otherwise playback freezes. I tested this PR merged on one of my account which has playback issues and it didn't fix it.

So, YouTube playback freezes because the locally cached PoToken is invalid — this isn't an OAuth issue. On detection, the player should regenerate the PoToken via the appropriate internal method instead of relying on the cached one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🔒 Integrity Play Integrity, SafetyNet, DroidGuard and ReCAPTCHA

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants