7 Replies Latest reply on Feb 29, 2016 10:16 AM by tacom_Hugo

    Whats wrong? "plugin unsupported: de.appplant.cordova.plugin.background-mode"

    tacom_Hugo Level 1

      Hello Friends!

       

      When I try to build my project at phonegap Build, the screen shows the following error message: "plugin unsupported: de.appplant.cordova.plugin.background-mode"

      I need to use this plugin, so, what I have to do?

       

      There is the fllowing lines in my config.xml:

       

      <plugin name="nl.x-services.plugins.insomnia"/>

      <plugin name="cordova-plugin-vibration"    source="npm" />

      <plugin name="cordova-plugin-device" source="npm" />

      <plugin name="cordova-plugin-dialogs" source="npm" />

      <plugin name="cordova-plugin-file-transfer" source="npm" />

      <plugin name="cordova-plugin-geolocation" source="npm" />

      <plugin name="cordova-plugin-inappbrowser" source="npm" />

      <plugin name="cordova-plugin-network-information" source="npm" />

      <plugin name="phonegap-plugin-mobile-accessibility" source="npm"  />

      <plugin name="cordova-plugin-statusbar" source="npm" />

      <plugin name="cordova-plugin-local-notifications-pgb" source="npm" />

      <gap:plugin name="de.appplant.cordova.plugin.background-mode" />

       

      Thanks,

      Hugo.

        • 1. Re: Whats wrong? "plugin unsupported: de.appplant.cordova.plugin.background-mode"
          kerrishotts Adobe Community Professional

          I'd suggest using the modern plugin tag. Also, if you don't specify a "source", "npm" is assumed, but the plugin isn't available on npm that I can see, so you'll need to reference the PGB version, like so:

           

          <plugin name="de.appplant.cordova.plugin.background-mode" spec="0.6.4" source="pgb" />
          

           

          (The deprecated gap:plugin tag defaults to PGB if no source is specified.)

           

          When I looked up the plugin on PGB, it indicates it had recently been updated. You might want to try an alternative version (0.6.3 or the like; change the value of "spec") to see if that works.

           

          I also noticed that PGB indicates that this plugin has a dependency on the device plugin @ 0.2.12. The current version from npm is actually @ 1.1.1. It's possible that will also cause a problem, but one step at a time.

          • 2. Re: Whats wrong? "plugin unsupported: de.appplant.cordova.plugin.background-mode"
            tacom_Hugo Level 1

            Hey Kerrishotts, thanks for the reply.

             

            I followed your suggestion, I tryied all versions of this plugin, but same problem in all versions, the app no build due this error message: plugin unsupported: de.appplant.cordova.plugin.background-mode @ 0.6.4

             

            So, I change the cordova-plugin-device to <plugin name="org.apache.cordova.device"  spec="0.2.12" source="pgb" />, but PhonegapBuild shows the error message: plugin unsupported: org.apache.cordova.device @ 0.2.12

             

            Well, I tryied the new git-backed reference:

            <plugin spec="katzer/cordova-plugin-background-mode.git" source="git" />

            This time the PhoneGap Build try to build, but shows the following error message:

            Error - Plugin error (you probably need to remove plugin files from your app): //github.com/katzer/cordova-plugin-background-mode.git": Fetching plugin "https://github.com/katzer/cordova-plugin-background-mode.git" via git clone Repository "https://github.com/katzer/cordova-plugin-background-mode.git" checked out to git ref "master". Installing "de.appplant.cordova.plugin.background-mode@0.6.4" for ios WARNING: org.apache.cordova.device has been renamed to cordova-plugin-device. You may not be getting the latest version! We suggest you `cordova plugin rm org.apache.cordova.device` and `cordova plugin add cordova-plugin-device`. Changing plugin to "cordova-plugin-device" Fetching plugin "cordova-plugin-device" via npm Failed to install 'de.appplant.cordova.plugin.background-mode':Error: Expected plugin to have ID "org.apache.cordova.device" but got "cordova-plugin-device".at checkID (/usr/local/lib/node_modules/pgb-plugman/node_modules/pgb-cordova-lib/src/plugman/fetch.j s:177:15) at /usr/local/lib/node_modules/pgb-plugman/node_modules/pgb-cordova-lib/src/plugman/fetch.js :161:9 at _fulfilled (/usr/local/lib/node_modules/pgb-plugman/node_modules/q/q.js:787:54) at self.promiseDispatch.done (/usr/local/lib/node_modules/pgb-plugman/node_modules/q/q.js:816:30) at Promise.promise.promiseDispatch (/usr/local/lib/node_modules/pgb-plugman/node_modules/q/q.js:749:13) at /usr/local/lib/node_modules/pgb-plugman/node_modules/q/q.js:557:44 at flush (/usr/local/lib/node_modules/pgb-plugman/node_modules/q/q.js:108:17) at doNTCallback0 (node.js:417:9) at process._tickCallback (node.js:346:13) Expected plugin to have ID "org.apache.cordova.device" but got "cordova-plugin-device".

             

             

            Sorry for english mistakes,

            Thanks,

            Hugo.

            • 3. Re: Whats wrong? "plugin unsupported: de.appplant.cordova.plugin.background-mode"
              kerrishotts Adobe Community Professional

              Hugo,

               

              I think you are out of luck at the moment. I suggest creating an issue at the plugin's repository so that the plugin author can address the issue. I suspect that once they update to the more recent device plugin, things will probably go more smoothly.

               

              One other thing I feel I should point out: this plugin will keep your app out of the Apple app store, because it's abusing the background modes by pretending to play audio. Just thought you ought to be aware.

              • 4. Re: Whats wrong? "plugin unsupported: de.appplant.cordova.plugin.background-mode"
                tacom_Hugo Level 1

                Kerrishotts,

                 

                Well, I created an issue about this problem at the plugin repository and I hope the be answered, hehehe. Thanks for this suggestion.

                 

                Oh, and yes, you're right, I had some trouble about the 'Background Audio' with Apple team some months ago, but I explained the why this plugin uses this resource and the Apple team released my app at the App store.

                 

                Thank you very much!

                Hugo.

                • 5. Re: Whats wrong? "plugin unsupported: de.appplant.cordova.plugin.background-mode"
                  tacom_Hugo Level 1

                  Hello Kerrishotts,

                  My issue was answered!

                  This plugin was updated and now its on NPM repo. It´s working again!

                   

                  Thanks for all help!

                  Hugo.

                  • 6. Re: Whats wrong? "plugin unsupported: de.appplant.cordova.plugin.background-mode"
                    ryanskihead Adobe Employee

                    Can you link to your solution and mark this as answered? Thanks

                    • 7. Re: Whats wrong? "plugin unsupported: de.appplant.cordova.plugin.background-mode"
                      tacom_Hugo Level 1

                      Ok, the solution is here: https://github.com/katzer/cordova-plugin-background-mode/issues/139

                       

                      Now we have to use the tag <plugin name="cordova-plugin-background-mode" source="npm" />.

                       

                      Thanks!