Search code examples
flutterdarthuawei-mobile-servicespubspechuawei-account

The current version does not meet the minimum version requirements - Huawei Account Kit integration [Flutter]


I am trying to integrate Huawei Account Kit in my flutter project. Since I am not using Huawei phone, I have downloaded the HMS Core in my phone which is version 3.0.0.300. The current version for Huawei Account Kit in my pubspec.yaml is 5.2.0+301.

I have already change the minSdkVersion to 19 before that. When I run my app, it says that I have not met the minimum version requirement. Any suggestions on solving this issue?

Below are my pubspec.yaml and some screenshot of the error messages.

name: account_kit
description: A new Flutter project.

version: 1.0.0+1

environment:
  sdk: ">=2.12.0 <3.0.0"

dependencies:
  flutter:
    sdk: flutter

  cupertino_icons: ^1.0.2
  huawei_account: ^5.2.0+301

dev_dependencies:
  flutter_test:
    sdk: flutter

flutter:
  uses-material-design: true

enter image description here

enter image description here


Solution

  • You could follow this Docs, try to configure Metadata:

    <application ...>
        <meta-data     
            android:name="com.huawei.hms.client.channel.androidMarket"  
            android:value="false" />
        ...
    </application>