[Magisk] gps3dx:
don't look at UI for 100% indication to what happening in "the background" of the system.

open shell and run the following to check the GP permissions current "grant status" ( which is either true or false ).

dumpsys package com.android.vending | grep -i permission

you also need to run "npem" command in shell to give GP sig spoof permission ( that is, after you patch the rom or using rom with builtin sig spoof solution ).

---------- Post added at 11:46 PM ---------- Previous post was at 11:23 PM ----------

@Setialpha - Me and many other users in the last few weeks/months are complaining about inability to restore purchased apps from GP.

The issue is happening when using Nanodroid's MicroG core together with your PATCHED GP

ON Q ANDR. ( AOSP based, NOT LOS ! )

When me and others enters GP -> account -> purchase history, we can see all the apps we owns, but when we click 'view' on one of the apps, we get a button with a price, instead of 'install' button.

that is true even if you search the app through GP search bar.

I looked at logcat and found few problems...here it is, reduced from personal info.

12-15 23:26:13.878 18481 18481 E Finsky : [2] fsl.a(26): Failed to fetch user data from account manager.
12-15 23:26:13.878 18481 18481 E Finsky : com.google.android.flib.log.WhatATerribleException: java.lang.SecurityException: uid 10059 cannot get user data for accounts of type: com.google
12-15 23:26:13.878 18481 18481 E Finsky : at aane.b(PG:3)
12-15 23:26:13.878 18481 18481 E Finsky : at com.google.android.finsky.utils.FinskyLog.b(PG:5)
12-15 23:26:13.878 18481 18481 E Finsky : at fsl.a(PG:26)
12-15 23:26:13.878 18481 18481 E Finsky : at fjx.a(PG:7)
12-15 23:26:13.878 18481 18481 E Finsky : at fco.a(PG:2)
12-15 23:26:13.878 18481 18481 E Finsky : at iot.a(PG:8)
12-15 23:26:13.878 18481 18481 E Finsky : at fcr.onStart(PG:6)
12-15 23:26:13.878 18481 18481 E Finsky : at android.app.Instrumentation.callActivityOnStart(Instrumentation.java:1432)
12-15 23:26:13.878 18481 18481 E Finsky : at android.app.Activity.performStart(Activity.java:7847)
12-15 23:26:13.878 18481 18481 E Finsky : at android.app.ActivityThread.handleStartActivity(ActivityThread.java:3294)
12-15 23:26:13.878 18481 18481 E Finsky : at android.app.servertransaction.TransactionExecutor.performLifecycleSequence(TransactionExecutor.java:221)
12-15 23:26:13.878 18481 18481 E Finsky : at android.app.servertransaction.TransactionExecutor.cycleToPath(TransactionExecutor.java:201)
12-15 23:26:13.878 18481 18481 E Finsky : at android.app.servertransaction.TransactionExecutor.executeLifecycleState(TransactionExecutor.java:173)
12-15 23:26:13.878 18481 18481 E Finsky : at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:97)
12-15 23:26:13.878 18481 18481 E Finsky : at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2016)
12-15 23:26:13.878 18481 18481 E Finsky : at android.os.Handler.dispatchMessage(Handler.java:107)
12-15 23:26:13.878 18481 18481 E Finsky : at android.os.Looper.loop(Looper.java:214)
12-15 23:26:13.878 18481 18481 E Finsky : at android.app.ActivityThread.main(ActivityThread.java:7356)
12-15 23:26:13.878 18481 18481 E Finsky : at java.lang.reflect.Method.invoke(Native Method)
12-15 23:26:13.878 18481 18481 E Finsky : at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:492)
12-15 23:26:13.878 18481 18481 E Finsky : at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:930)
12-15 23:26:13.878 18481 18481 E Finsky : Caused by: java.lang.SecurityException: uid 10059 cannot get user data for accounts of type: com.google
12-15 23:26:13.878 18481 18481 E Finsky : at android.os.Parcel.createException(Parcel.java:2071)
12-15 23:26:13.878 18481 18481 E Finsky : at android.os.Parcel.readException(Parcel.java:2039)
12-15 23:26:13.878 18481 18481 E Finsky : at android.os.Parcel.readException(Parcel.java:1987)
12-15 23:26:13.878 18481 18481 E Finsky : at android.accounts.IAccountManager$Stub$Proxy.getUserData(IAccountManager.java:1441)
12-15 23:26:13.878 18481 18481 E Finsky : at android.accounts.AccountManager.getUserData(AccountManager.java:514)
12-15 23:26:13.878 18481 18481 E Finsky : at fsl.a(PG:28)
12-15 23:26:13.878 18481 18481 E Finsky : ... 18 more
12-15 23:26:13.878 18481 18481 E Finsky : Caused by: android.os.RemoteException: Remote stack trace:
12-15 23:26:13.878 18481 18481 E Finsky : at com.android.server.accounts.AccountManagerService.getUserData(AccountManagerService.java:1542)
12-15 23:26:13.878 18481 18481 E Finsky : at android.accounts.IAccountManager$Stub.onTransact(IAccountManager.java:492)
12-15 23:26:13.878 18481 18481 E Finsky : at com.android.server.accounts.AccountManagerService.onTransact(AccountManagerService.java:1072)
12-15 23:26:13.878 18481 18481 E Finsky : at android.os.Binder.execTransactInternal(Binder.java:1021)
12-15 23:26:13.878 18481 18481 E Finsky : at android.os.Binder.execTransact(Binder.java:994)
12-15 23:26:13.878 18481 18481 E Finsky :
12-15 23:26:13.862 1410 1635 E NotificationService: Suppressing notification from package by user request.
12-15 23:26:13.881 1410 20009 I DropBoxManagerService: add tag=system_app_wtf isTagEnabled=true flags=0x2
12-15 23:26:13.891 18481 18562 W GooglePlayServicesUtil: Google Play services out of date. Requires 19677000 but found 19420019
12-15 23:26:13.899 18481 18562 D acil : File /data/user/0/com.android.vending/cache/1561154238473.dex not found. No need for deletion
12-15 23:26:13.900 18481 20010 W ContextImpl: Failed to ensure /data/user/0/com.google.android.gms/shared_prefs: mkdir failed: EACCES (Permission denied)
12-15 23:26:13.912 3601 3856 D GmsAuthenticator: getAuthToken: Account {name=*****@gmail.com, type=com.google}, oauth2:https://www.googleapis.com/auth/accounts.reauth, Bundle[{androidPackageName=com.android.vending, callerPid=18481, callerUid=10059}]
12-15 23:26:13.913 3151 3151 D checkDoubleClick: click
12-15 23:26:13.939 3601 3856 D GmsAuthManager: peekAuthToken: com.android.vending:92873409273498723948723948723948723948298:oauth2:https://www.googleapis.com/auth/accounts.reauth
12-15 23:26:13.953 3151 3151 D stopWindow: findFocus not editable
12-15 23:26:13.957 3601 3856 D GmsAuthenticator: getAuthToken: ko3j4nto34nto3k4nt039rgj3-049ogj3049gj3049gj3094ijg0394gjelrkgno3ik4rgjn304igj3049gj3[049gj3049gj3094jg
12-15 23:26:13.979 18481 18599 I PlayCommon: [149] ajcz.c(29): Preparing logs for uploading
12-15 23:26:13.993 3601 3856 D GmsAuthenticator: getAuthToken: Account {name=******@gmail.com, type=com.google}, oauth2:https://www.googleapis.com/auth/googleplay, Bundle[{androidPackageName=com.android.vending, callerPid=18481, callerUid=10059, notifyOnAuthFailure=true}]
12-15 23:26:14.007 3601 3856 D GmsAuthManager: peekAuthToken: com.android.vending:92873409273498723948723948723948723948298:oauth2:https://www.googleapis.com/auth/googleplay
12-15 23:26:14.010 3601 3856 D GmsAuthenticator: getAuthToken: ya29.pojwefpoje-r92iu3-f92j30f-92j3f0-923jf-293jf-923jf029hf023h8f023hg203hg-022934gh3-094gh2-93ghgf0293eh2093fhj0293hf2983fh2938fh2938hf9238fh90283hf923hrf9823hf90283hf9283hf
12-15 23:26:14.013 3151 3151 D stopWindow: findFocus not editable
12-15 23:26:14.018 18481 18599 I PlayCommon: [149] ajcz.c(185): Connecting to server: https://play.googleapis.com/play/log?format=raw&proto_v2=true
12-15 23:26:14.072 18481 20011 E Finsky : [268] fsl.c(21): Failed to update reauth settings cache.
12-15 23:26:14.072 18481 20011 E Finsky : com.google.android.flib.log.WhatATerribleException
12-15 23:26:14.072 18481 20011 E Finsky : at aane.f(PG:2)
12-15 23:26:14.072 18481 20011 E Finsky : at com.google.android.finsky.utils.FinskyLog.e(PG:3)
12-15 23:26:14.072 18481 20011 E Finsky : at fsl.c(PG:21)
12-15 23:26:14.072 18481 20011 E Finsky : at fju.doInBackground(PG:3)
12-15 23:26:14.072 18481 20011 E Finsky : at android.os.AsyncTask$3.call(AsyncTask.java:378)
12-15 23:26:14.072 18481 20011 E Finsky : at java.util.concurrent.FutureTask.run(FutureTask.java:266)
12-15 23:26:14.072 18481 20011 E Finsky : at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:289)
12-15 23:26:14.072 18481 20011 E Finsky : at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
12-15 23:26:14.072 18481 20011 E Finsky : at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
12-15 23:26:14.072 18481 20011 E Finsky : at java.lang.Thread.run(Thread.java:919)

As you can see there's few issues:

Finsky : [2] fsl.a(26): Failed to fetch user data from account manager.

Caused by: java.lang.SecurityException: uid 10059 cannot get user data for accounts of type: com.google

ContextImpl: Failed to ensure /data/user/0/com.google.android.gms/shared_prefs: mkdir failed: EACCES (Permission denied)

Finsky : [268] fsl.c(21): Failed to update reauth settings cache.

MicroG Core & GP got all the permissions the apps can request inc 'android.permission.FAKE_PACKAGE_SIGNATURE' by running npem

( I verified using 'dumpsys package' command ).

Any idea how to solve the issue and gaining back the ability to restore purchsed apps from GP ?

UPDATE:

a possible solution has NOTHING to do with any Nanodroid components...

I disable 'Adaway' (ad blocker app) AND 'AFWALL+' (a firewall app) -> closed GP from recents -> opened GP, went to the purchased apps list then ALL OF THEM allowed me to install them ( instead of giving me a price button ) as SHOULD. :eek::eek: