Anteneh Negash
Anteneh Negash

Reputation: 99

OneSignal-Cordova-SDK fails when added on ionic 2 project

OneSignal-Cordova-SDK fails when added on ionic 2 project Latest version is 2.2.2

Failed to install 'onesignal-cordova-plugin': Error: pod: Command failed with exit code 31 at ChildProcess.whenDone (APP_LOCATION/platforms/ios/cordova/node_modules/cordova-common/src/superspawn.js:169:23) at emitTwo (events.js:125:13) at ChildProcess.emit (events.js:213:7) at maybeClose (internal/child_process.js:927:16) at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5)

Failed to restore plugin "onesignal-cordova-plugin" from config.xml. You might need to try adding it again. Error: Error: pod: Command faileenter code hered with exit code 31

Upvotes: 2

Views: 583

Answers (2)

Anteneh Negash
Anteneh Negash

Reputation: 99

I actually figured out the problem.

if you add(or upgrade) one signal, it uses the latest dependencies that have to be downloaded using cocoapods.

running "pod repo update"

should fix the problem.

Upvotes: 2

Sampath
Sampath

Reputation: 65920

Just follow these steps.

  1. Remove node_modules folder

  2. npm i

If it won't work after that too:

Then uninstall onesignal plugin and reinstall it again.

Upvotes: 1

Related Questions