question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Install fails with "Path must be a string. Received undefined"

See original GitHub issue
➜  phonegap git:(master) ✗ cordova plugin add https://github.com/danwilson/google-analytics-plugin.git
Fetching plugin "https://github.com/danwilson/google-analytics-plugin.git" via git clone
Repository "https://github.com/danwilson/google-analytics-plugin.git" checked out to git ref "master".
Installing "cordova-plugin-google-analytics" for android
Error during processing of action! Attempting to revert...
Failed to install 'cordova-plugin-google-analytics':TypeError: Uh oh!
Path must be a string. Received undefined
    at assertPath (path.js:8:11)
    at Object.posix.resolve (path.js:424:5)
    at Object.module.exports.framework.install (/usr/local/lib/node_modules/cordova/node_modules/cordova-lib/src/plugman/platforms/android.js:139:35)
    at installWrapper (/usr/local/lib/node_modules/cordova/node_modules/cordova-lib/src/platforms/platforms.js:77:32)
    at Object.ActionStack.process (/usr/local/lib/node_modules/cordova/node_modules/cordova-lib/src/plugman/util/action-stack.js:68:25)
    at handleInstall (/usr/local/lib/node_modules/cordova/node_modules/cordova-lib/src/plugman/install.js:576:20)
    at /usr/local/lib/node_modules/cordova/node_modules/cordova-lib/src/plugman/install.js:363:28
    at _fulfilled (/usr/local/lib/node_modules/cordova/node_modules/q/q.js:787:54)
    at self.promiseDispatch.done (/usr/local/lib/node_modules/cordova/node_modules/q/q.js:816:30)
    at Promise.promise.promiseDispatch (/usr/local/lib/node_modules/cordova/node_modules/q/q.js:749:13)

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Reactions:1
  • Comments:18 (1 by maintainers)

github_iconTop GitHub Comments

3reactions
jimcamutcommented, May 16, 2016

It could be a permissions issue as it was for me. Try removing the platform and then adding it back, which will reset the permissions.

1reaction
brunogyn88commented, May 30, 2017

sudo ionic state reset sudo ionic plugin remove cordova-plugin-googlemaps

Read more comments on GitHub >

github_iconTop Results From Across the Web

"Path must be a string. Received undefined" #144 - zkat/npx
So I found that it is not running node as expected. Normally npx does node to run your js. But sometimes, on windows...
Read more >
Jest TypeError: Path must be a string. Received undefined
I solved this issue using: npm uninstall -g jest; npm install -g jest; npm cache clean; npm install.
Read more >
Path must be a string. Received undefined
1 Answer 1 ... Try using a higher version of node. npm install -g npm@5.8.0 npm install -g npx@10.0.1.
Read more >
Installation failed: The "path" argument must be type string. ...
Getting the following error when trying to install a world - Installation failed: The "path" argument must be type string. Received undefined. I ......
Read more >
npx webpack prints a "Path must be a string. Received ...
I did try npm install -g npx , but it didn't seem to affect the output. I still cannot do node webpack or...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found