Search code examples
node.jscordovavisual-studio-2015geolocationtaco

Getting Build Error for Cordova plugin integration on Visual Studio 2015 TACo


This is regarding Cordova based universal app development using Visual Studio 2015 - Tools for Apache Cordova (TACo).

Here is the sample code which I am trying to run: AngularJSToDo app. In this app, there is GeoLocation Cordova plugin is being used. In config.xml:

<vs:plugin name="org.apache.cordova.geolocation" version="0.3.10" />

While building application for Windows Phone Emulator 8.1, it throws an error after below process:

------ Adding plugin: [email protected]

1> Calling plugman.fetch on plugin "[email protected]"

1> Fetching plugin "[email protected]" via plugin registry

1>MDAVSCLI : error : read ECONNRESET

This error appears after a long time fetching event. I have already tried installing particular plugin using "npm" command through command prompt, but VS build automatically clears older plugins and re-download and install latest ones.

In error section, it says

"read ECONNRESET"

Please guide me what should be done to resolve this error from Visual Studio build.

Reference: https://taco.visualstudio.com/en-us/docs/create-a-hosted-app/


Solution

  • This issue had been resolved by restarting node(npm) server. Below are the steps what I did.

    • Terminal - Ctrl+C to stop the npm server
    • Go to particular project folder, and add the plugins using below command

      cordova plugin add <plugin-name>

    • Restart the node server: remotebuild

    Hope this helps to others.