Skip to content

minSdkVersion 16 cannot be smaller than version 19 #183

@KakarN

Description

@KakarN

I am would like to integrate Razorpay into my react-native app. I have installed the razorpay package and have also linked successfully.

However, when I try to run the app I am getting the following errors:

$ react-native run-android

info Starting JS server...
info Building and installing the app on the device (cd android && ./gradlew app:installDebug)...

> Configure project :react-native-razorpay
WARNING: The specified Android SDK Build Tools version (26.0.3) is ignored, as it is below the minimum supported version (28.0.3) for Android Gradle Plugin 3.3.1.
Android SDK Build Tools 28.0.3 will be used.
To suppress this warning, remove "buildToolsVersion '26.0.3'" from your build.gradle file, as each version of the Android Gradle Plugin now has a default version of the build tools.

> Task :app:processDebugManifest FAILED
/Users/kakarnyori/react-native-projects/RazorpayTest/android/app/src/debug/AndroidManifest.xml Error:
        uses-sdk:minSdkVersion 16 cannot be smaller than version 19 declared in library [com.razorpay:checkout:1.5.5] /Users/kakarnyori/.gradle/caches/transforms-1/files-1.1/checkout-1.5.5.aar/a23f27ddc59bc933dbac2f4019e7fbab/AndroidManifest.xml as the library might be using APIs not available in 16
        Suggestion: use a compatible library with a minSdk of at most 16,
                or increase this project's minSdk version to at least 19,
                or use tools:overrideLibrary="com.razorpay" to force usage (may lead to runtime failures)

See http://g.co/androidstudio/manifest-merger for more information about the manifest merger.


FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:processDebugManifest'.
> Manifest merger failed : uses-sdk:minSdkVersion 16 cannot be smaller than version 19 declared in library [com.razorpay:checkout:1.5.5] /Users/kakarnyori/.gradle/caches/transforms-1/files-1.1/checkout-1.5.5.aar/a23f27ddc59bc933dbac2f4019e7fbab/AndroidManifest.xml as the library might be using APIs not available in 16
        Suggestion: use a compatible library with a minSdk of at most 16,
                or increase this project's minSdk version to at least 19,
                or use tools:overrideLibrary="com.razorpay" to force usage (may lead to runtime failures)

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 1s
22 actionable tasks: 1 executed, 21 up-to-date
error Could not install the app on the device, read the error above for details.
Make sure you have an Android emulator running or a device connected and have
set up your Android development environment:
https://facebook.github.io/react-native/docs/getting-started.html
error Command failed: ./gradlew app:installDebug. Run CLI with --verbose flag for more details.

I have been using Expo to develop mobile apps, and I am very new to Android development. Could you please tell me how can I fix this?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions