Application Build errors


#1

My Appstudio version is 7.0.2.

I am trying to rebuild my app and deploy to Phonegap after upgrading a plugin from an earlier version. I am now getting the following error while compiling:

    Fetching plugin "cordova-plugin-mauron85-background-geolocation@2.3.6" via npm
    Installing "cordova-plugin-mauron85-background-geolocation" at "2.3.6" for android
    Plugin doesn't support this project's cordova-android version. cordova-android: 6.1.2, failed version requirement: >=6.3.0**
    Skipping 'cordova-plugin-mauron85-background-geolocation' for android

I have tried updating the config XML section with the following settings to attempt to increase the cordova android version - to no avail. Does anyone know how to do this?

I tried this…

    <gap:platforms>
       <gap:platform name="android" minVersion="6.3.0" />
       <gap:platform name="ios" />
       <gap:platform name="winphone" />
    </gap:platforms>

Then I also tried this.

    <!-- Minimum version required for the mauron plugin -->
    <engine name="android" spec="^6.3.0" />

No luck with either of these. Any ideas?


#2

I think you need to specify the minimum Android version using something like this in config.xml:

<preference name="android-minSdkVersion" value="21"/>

The “value” is the API level. Here’s a table of values:


#3

OK, if I read the table properly, then Android 7.0 is API version 24, so I tried the following in the main line of the config.xml:

<preference name="android-minSdkVersion" value="24"/>

I also tried putting it into the platform tag like so:

<platform name="android">        
        <!--Minimum version required for the mauron plugin -->
        <preference name="android-minSdkVersion" value="24" />
</platform>

Neither of these worked, still get the same error.


#4

It seems like I am unable to control the build version of cordova used no matter what I do. Is this an AppStudio issue or a phonegap issue. I have posted this issue there as well and found a number of posts with the exact same error - no answers to any of them. Do they even monitor this anymore?

Installing "cordova-plugin-mauron85-background-geolocation" at "2.3.6" for android Plugin doesn't support this project's cordova-android version. cordova-android: 6.1.2, failed version requirement: &gt;=6.3.0

I have wasted 2 days on this…


#5

Finally found a reply on phonegap, someone apparently uploaded some incorrect packages to jcenter and it has caused this issue. It is a known issue in cordova and there is a general solution being worked on, so it is not an issue caused by build. This has been an issue for over 3 days now, doesn’t look like they are in any hurry to fix.


#6

I also found an article that fixed my issue - I changed the phonegap version in my project properties and that fixed my problem.:grinning:

This page helped me - the default build is in bold and it was controlling my cordova build version. Once I changed my phonegap version to “cli-7.1.0” the issue was resolved.

https://build.phonegap.com/current-support


#7

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.