I had the same problem, in my case the reason was that I had a flag set in the intent that triggered the action in which the purchase process was located
i.addFlags (Intent.FLAG_ACTIVITY_NO_HISTORY);
after deleting the flag it works, I assume that this is because when startIntentSenderForResult starts the purchase interface, the activity is destroyed, it is not saved in the history, and for some reason there is no point in processing onActivityResult
source share