Using Google Play Billing Library 5.0.0 with purchases_flutter 3.10.0

  • 17 July 2022
  • 8 replies


I use on my application and purchases_flutter 3.10.0 for the revenuecat subscriptions.

From May 2022, users can't see the free trial or intro price options. Then, I messaged the GooglePlay and they replied as below:

Hello Google Play Developer, Due to a bug in our system, since May 3, 2022, you may be experiencing incorrect or missing subscription information in the results from the Google Play Billing library’s deprecated querySkuDetailsAsync() function. During this time the Google Play Billing library may not have returned information to your apps about free trial and intro price offers for one or more of your subscriptions, even if the user was eligible for these offers. In these cases, users only saw the subscription base plan in the purchase cart, without any free trials or intro prices.

Action Required

We recommend that you review all of your subscriptions with free trial and intro price offers in the Play Console, and ensure that the correct offers are active and marked as backward compatible. You can learn more about backwards compatibility here.

If your app uses the queryProductDetailsAsync() function instead, this is not impacted and you do not need to take any action.


Then, I wanted to try migrate blling library from 4.0.0 to 5.0.0. However, after the migration, I got the following error and app crashed.

E/AndroidRuntime( 4198): java.lang.NoSuchMethodError: No virtual method queryPurchases(Ljava/lang/String;)Lcom/android/billingclient/api/Purchase$PurchasesResult; in class Lcom/android/billingclient/api/BillingClient; or its super classes (declaration of ''

Could anyone help with the solution?

8 replies

Userlevel 1
Badge +1

We're working on updating our SDKs for compatibility with Billing Client 5.0. There have been some changes in the way Google subscriptions work so we still need to make some changes across our services.

In the meantime, our SDK currently uses Billing Client 4.0 and it’s not possible to use it alongside BillingClient 5.

We wrote a post about the Google I/O announcements and Billing Client 5 which might help provide more context here.

Everything that's marked as "Backwards Compatible" in the Play Console works with our SDK.

We were not aware of that Google’s bug so thanks for letting us know, we’ll keep an eye for more reports about it.

Userlevel 4
Badge +10


We're working on updating our SDKs for compatibility with Billing Client 5.0. 
In the meantime, our SDK currently uses Billing Client 4.0. The Billing Client is a transitive dependency on the SDK, so you should only need to install our SDK and don't need to manually manage the Billing Client version.

Hey @Cesar is there a timeline for this migration update or should I just revert my client to 4.0 and wait?


@Alberto Arciniegas  +1 . I alo wonder this update

Userlevel 1
Badge +1

We are actively working on it and we can’t provide an ETA yet. There have been a lot of changes on the way subscriptions work that require us to also change our backend and configuration dashboard in order to support BillingClient 5 and the new subscription system. I am sorry we can’t provide a more specific answer but we are still trying to figure some things out.

I would revert your client to 4 until further notice.

cc: @AnnaToro 

have you change build.gradle ,the billing version?


To clarify, in order to get this to work at all right now we need to use:

implementation 'com.revenuecat.purchases:purchases:4.6.1'

… instead of any of the 5.x.x implementations?

Is that correct?

Userlevel 1
Badge +1

To clarify: our SDK version 5.x.x still depends on `` version 4. This dependency is automatically added to your project when including `com.revenuecat.purchases:purchases:` in your project and you don’t have to also declare a dependency on the billingclient. Including our SDK will download the correct dependency that should be used along with it.

As of today, version 5.x.x of `com.revenuecat.purchases:purchases:` still depends on version 4 of ``. Version 5.x.x of our SDK is the one you should be using. We are working on updating our SDK version 5.x.x to depend on billingclient 5.