You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cordova.apache.org by "Carlos Santana (JIRA)" <ji...@apache.org> on 2016/03/03 18:22:18 UTC

[jira] [Commented] (CB-10770) cordova cli not adding platform via npm specifying new version before 24 hours of release

    [ https://issues.apache.org/jira/browse/CB-10770?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15178170#comment-15178170 ] 

Carlos Santana commented on CB-10770:
-------------------------------------

We could fix this by catching the error and trying again with a default or lower cache-min, default is 10 seconds

[~stevegill] might have a better way to handle this now, and how we should handle in the future when we use external npm

I don't know the history behind changing the default and use 24 hours, I think is useful allows you to work with projects with offline (add platforms, plugins) without having access to npm registry.

 

> cordova cli not adding platform via npm specifying new version before 24 hours of release
> -----------------------------------------------------------------------------------------
>
>                 Key: CB-10770
>                 URL: https://issues.apache.org/jira/browse/CB-10770
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: CLI
>    Affects Versions: 6.0.0
>         Environment: Mac
>            Reporter: Carlos Santana
>            Priority: Minor
>              Labels: CLI
>
> A new release of platform ios cordova-ios@4.1.0 is published to NPM
> User tries to install with $ cordova platform ios@4.1.0
> At the time of this command the npm cache information for the pacakge cordova-ios in ~/.cordova/lib/npm_cache/registry.npmjs.org/cordova-ios/.cache.json doesn't have the information about 4.1.0 and the file is not older than 24 hours.
> cordova cli is configured with npm cache-min = 3600*24 (24 hours)
> If the file in the cache is not older than 24 hours npm will not check the registry. and requested package cordova-ios@4.1.0 is not added to the cache.
> There is no err catch for this case in the cordova-lib [1]
> [1]: https://github.com/apache/cordova-lib/blob/master/cordova-lib/src/cordova/lazy_load.js#L158



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

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org