Skip to content
This repository has been archived by the owner on Oct 1, 2018. It is now read-only.

[1.1.2] Error during installation #63

Closed
markshust opened this issue Jun 4, 2016 · 4 comments
Closed

[1.1.2] Error during installation #63

markshust opened this issue Jun 4, 2016 · 4 comments

Comments

@markshust
Copy link

markshust commented Jun 4, 2016

I'm receiving the following error when trying to install with Meteor 1.3. This happens at build-time when trying to run on ios-device:


=> Started proxy.                             
=> Started MongoDB.                           
Installing dependency packages:              [====================       ] 75% 6.5s
{
  "mkpath": ">=1.0.0",
  "xml2js": ">=0.4",
  "rimraf": ">=2.4",
  "node-version-compare": ">=1.0.1",
  "plist": ">=1.2.0"
}
% Failed to install 'cordova-universal-links-plugin':TypeError: undefined is not a function
    at module.exports (/Users/markshust/Sites/foo/.meteor/local/cordova-build/plugins/cordova-universal-links-plugin/hooks/beforePluginInstallHook.js:49:16)
    at runScriptViaModuleLoader (/Users/markshust/.meteor/packages/meteor-tool/.1.3.2_4.1o34fbp++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/lib/node_modules/cordova-lib/src/hooks/HooksRunner.js:167:18)
    at runScript (/Users/markshust/.meteor/packages/meteor-tool/.1.3.2_4.1o34fbp++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/lib/node_modules/cordova-lib/src/hooks/HooksRunner.js:145:16)
    at /Users/markshust/.meteor/packages/meteor-tool/.1.3.2_4.1o34fbp++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/lib/node_modules/cordova-lib/src/hooks/HooksRunner.js:130:20
    at _fulfilled (/Users/markshust/.meteor/packages/meteor-tool/.1.3.2_4.1o34fbp++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/lib/node_modules/q/q.js:787:54)
    at self.promiseDispatch.done (/Users/markshust/.meteor/packages/meteor-tool/.1.3.2_4.1o34fbp++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/lib/node_modules/q/q.js:816:30)
    at Promise.promise.promiseDispatch (/Users/markshust/.meteor/packages/meteor-tool/.1.3.2_4.1o34fbp++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/lib/node_modules/q/q.js:749:13)
    at /Users/markshust/.meteor/packages/meteor-tool/.1.3.2_4.1o34fbp++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/lib/node_modules/q/q.js:810:14
    at flush (/Users/markshust/.meteor/packages/meteor-tool/.1.3.2_4.1o34fbp++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/lib/node_modules/q/q.js:108:17)
    at process._tickCallback (node.js:458:13)
=> Errors executing Cordova commands:                                              

   While adding plugin cordova-universal-links-plugin@1.1.2 to Cordova project:    
   TypeError: undefined is not a function                                          
   at module.exports
   (/Users/markshust/Sites/foo/.meteor/local/cordova-build/plugins/cordova-universal-links-plugin/hooks/beforePluginInstallHook.js:49:16)
   at runScriptViaModuleLoader
   (/Users/markshust/.meteor/packages/meteor-tool/.1.3.2_4.1o34fbp++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/lib/node_modules/cordova-lib/src/hooks/HooksRunner.js:167:18)
   at runScript
   (/Users/markshust/.meteor/packages/meteor-tool/.1.3.2_4.1o34fbp++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/lib/node_modules/cordova-lib/src/hooks/HooksRunner.js:145:16)
   at
   /Users/markshust/.meteor/packages/meteor-tool/.1.3.2_4.1o34fbp++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/lib/node_modules/cordova-lib/src/hooks/HooksRunner.js:130:20
   at _fulfilled
   (/Users/markshust/.meteor/packages/meteor-tool/.1.3.2_4.1o34fbp++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/lib/node_modules/q/q.js:787:54)
   at self.promiseDispatch.done
   (/Users/markshust/.meteor/packages/meteor-tool/.1.3.2_4.1o34fbp++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/lib/node_modules/q/q.js:816:30)
   at Promise.promise.promiseDispatch
   (/Users/markshust/.meteor/packages/meteor-tool/.1.3.2_4.1o34fbp++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/lib/node_modules/q/q.js:749:13)
   at
   /Users/markshust/.meteor/packages/meteor-tool/.1.3.2_4.1o34fbp++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/lib/node_modules/q/q.js:810:14
   at flush
   (/Users/markshust/.meteor/packages/meteor-tool/.1.3.2_4.1o34fbp++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/lib/node_modules/q/q.js:108:17)
   at process._tickCallback (node.js:458:13)

/Users/markshust/.meteor/packages/meteor-tool/.1.3.2_4.1o34fbp++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/isopackets/cordova-support/npm/node_modules/meteor/promise/node_modules/meteor-promise/promise_server.js:116
      throw error;
            ^
ExitWithCode:1
@nikDemyankov
Copy link
Member

What version of node you are using? According to error message:

% Failed to install 'cordova-universal-links-plugin':TypeError: undefined is not a function
    at module.exports (/Users/markshust/Sites/foo/.meteor/local/cordova-build/plugins/cordova-universal-links-plugin/hooks/beforePluginInstallHook.js:49:16)

It can't find spawnSync method.

@markshust
Copy link
Author

meteor uses node 0.10

@nikDemyankov
Copy link
Member

Never used it, so will ask: it can't work with node 4+?

If not - then you can do the following:

  1. Fork this repo.

  2. Go to plugin.xml and remove line 28:

    <hook src="hooks/beforePluginInstallHook.js" type="before_plugin_install" />
  3. In your application remove ios and android platforms from the project:

    cordova platform remove ios android
    
  4. Add plugin with git link:

    cordova plugin add https://github.com/markoshust/cordova-universal-links-plugin.git
    
  5. Install plugin dependencies:

    cd YOUR_PROJECT/plugins/cordova-universal-links-plugin
    npm i
    
  6. Now you can add platforms to the project:

    cordova platform add ios android
    

So, the task is to install plugin dependencies before adding plugin to the platforms.

timestep added a commit to timestep/cordova-universal-links-plugin that referenced this issue Aug 4, 2016
bendechrai added a commit to bendechrai/cordova-universal-links-plugin that referenced this issue Feb 14, 2017
@nordnet-deprecation-bot
Copy link
Contributor

👋 Hi! Thank you for your interest in this repo.

😢 We are not using nordnet/cordova-universal-links-plugin anymore, and we lack the manpower and the experience needed to maintain it. We are aware of the inconveniece that this may cause you. Feel free to use it as is, or create your own fork.

🔒 This will now be closed & locked.

ℹ️ Please see #160 for more information.

@nordnet nordnet locked and limited conversation to collaborators Sep 19, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants