purchases_flutter uses or overrides a deprecated API

  • 17 October 2023
  • 2 replies

Badge +1

I am trying RevenueCat for the first time. When I compile my project in VS Code since including the purchases_flutter package (latest version: purchases_flutter: ^6.0.0), I receive this warning:

Note: C:\Users\User\AppData\Local\Pub\Cache\hosted\\purchases_flutter-6.0.0\android\src\main\java\com\revenuecat\purchases_flutter\ uses or overrides a deprecated API.

minSdkVersion is set to 30 (flutter.minSdkVersion=30)

Flutter Doctor info:
[√] Flutter (Channel stable, 3.13.7, on Microsoft Windows [Version 10.0.19045.3570], locale en-US)
[√] Windows Version (Installed version of Windows is version 10 or higher)
[√] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
[√] Chrome - develop for the web
[!] Visual Studio - develop Windows apps (Visual Studio Community 2017 15.8.1)  
    X Visual Studio 2019 or later is required.
[√] Android Studio (version 2022.3)
[√] VS Code (version 1.83.1)

How do I fix this problem?

Thank you.


Best answer by kaitlin 2 November 2023, 14:58

View original

2 replies

Badge +1

Can someone please answer this question?

This is the more detailed message after compiling with -Xlint:deprecation:

C:\Users\User\AppData\Local\Pub\Cache\hosted\\purchases_flutter-6.0.0\android\src\main\java\com\revenuecat\purchases_flutter\ warning: [deprecation] GoogleProrationMode in com.revenuecat.purchases.models has been deprecated

import com.revenuecat.purchases.models.GoogleProrationMode;

Userlevel 3
Badge +6

Hey @Talicom,

Thank you for bringing this to our attention! In Billing Client 6, `GoogleProrationMode` is deprecated, but there was one missed reference to it. This has since been fixed, and will be included in the next release of the Flutter SDK, which you can keep an eye out for here:

In the meantime, you should be safe to test while ignoring this warning, unless you are testing proration modes or DEFERRED replacement mode, in which you can just follow the instructions here: