Uploaded image for project: 'Apache Cordova'
  1. Apache Cordova
  2. CB-9163

Make engines error look less nasty

    XMLWordPrintableJSON

Details

    Description

      When installing the cordova-plugin-whitelist plugin (from master), and it doesn't fulfill the engine requirement, you get a scary error which is harmless.

      $ cordova plugin add https://github.com/apache/cordova-plugin-whitelist.git#master
      Fetching plugin "https://github.com/apache/cordova-plugin-whitelist.git" via git clone
      Repository "https://github.com/apache/cordova-plugin-whitelist.git" checked out to git ref "master".
      Installing "cordova-plugin-whitelist" for android
      Installing "cordova-plugin-whitelist" for ios
      Failed to install 'cordova-plugin-whitelist':CordovaError: Plugin doesn't support this project's cordova-ios version. cordova-ios: 3.8.0, failed version requirement: >=4.0.0-dev
          at checkEngines (/Users/shaz/Documents/Git/Apache/cordova-lib/cordova-lib/src/plugman/install.js:119:29)
          at /Users/shaz/Documents/Git/Apache/cordova-lib/cordova-lib/src/plugman/install.js:296:16
          at _fulfilled (/Users/shaz/Documents/Git/Apache/cordova-lib/cordova-lib/node_modules/q/q.js:787:54)
          at self.promiseDispatch.done (/Users/shaz/Documents/Git/Apache/cordova-lib/cordova-lib/node_modules/q/q.js:816:30)
          at Promise.promise.promiseDispatch (/Users/shaz/Documents/Git/Apache/cordova-lib/cordova-lib/node_modules/q/q.js:749:13)
          at /Users/shaz/Documents/Git/Apache/cordova-lib/cordova-lib/node_modules/q/q.js:557:44
          at flush (/Users/shaz/Documents/Git/Apache/cordova-lib/cordova-lib/node_modules/q/q.js:108:17)
          at process._tickCallback (node.js:419:13)
      Plugin doesn't support this project's cordova-ios version. cordova-ios: 3.8.0, failed version requirement: >=4.0.0-dev
      

      Change it to not have the stack-trace, and have a friendlier output. If you have the Android platform added, it succeeds in installing it also, but not sure if its because the platform tag appears first in plugin.xml (check).

      Attachments

        Issue Links

          Activity

            People

              stevegill Steve Gill
              shazron Shazron Abdullah
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: