Tom Vincent created CB-9503:
-------------------------------

             Summary: Adding a plugin with a caret version fails to resolve
                 Key: CB-9503
                 URL: https://issues.apache.org/jira/browse/CB-9503
             Project: Apache Cordova
          Issue Type: Bug
          Components: CordovaLib
    Affects Versions: 5.2.0
            Reporter: Tom Vincent


A regression seems to have been introduced after CB-9147 whereby caret 
versioned plugins cannot be installed even when the resolved version is a valid 
install target.

For example, the latest publish release of cordova-plugin-crosswalk-webview on 
npm is 1.2.0. However, when I {{cordova plugin add 
cordova-plugin-crosswalk-webview@\^1.2.0}}, it fails with "No compatible 
version found". The same thing succeeds with a tilde, or by reverting to 
cordova-lib 5.1.1.

Fuller example:

{code}
❯ ../../../node_modules/.bin/cordova -v
5.2.0

❯ ../../../node_modules/.bin/cordova plugin add 
cordova-plugin-crosswalk-webview@\^1.2.0
Fetching plugin "cordova-plugin-crosswalk-webview@^1.2.0" via npm
Failed to fetch plugin cordova-plugin-crosswalk-webview@^1.2.0 via registry.
Probably this is either a connection problem, or plugin spec is incorrect.
Check your connection and plugin name/version/URL.
Error: No compatible version found: cordova-plugin-crosswalk-webview@'">=1.2.0 
<2.0.0"'
Valid install targets:
["1.0.0","1.1.0","1.2.0"]

❯ npm i [email protected]

❯ ../../../node_modules/.bin/cordova -v
5.1.1

❯ ../../../node_modules/.bin/cordova plugin add 
cordova-plugin-crosswalk-webview@\^1.2.0
Fetching plugin "cordova-plugin-crosswalk-webview@^1.2.0" via npm
npm http GET https://registry.npmjs.org/cordova-plugin-crosswalk-webview
npm http 304 https://registry.npmjs.org/cordova-plugin-crosswalk-webview
Installing "cordova-plugin-crosswalk-webview" for android
{code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to