podio / podio-js

Official Podio JavaScript SDK for node and the browser
http://podio.github.io/podio-js/
MIT License
45 stars 49 forks source link

Server Auth Example fails to run #50

Closed Rafase282 closed 7 years ago

Rafase282 commented 7 years ago

I cloned the file, created the ./config.json and added the right information. However, when I try to run, I get the following error:

cc: @flyblackbox

rafase282@rafase282-Lenovo-Z70-80:~/Workspace/Pairing/podio-js/examples/server_auth$ npm start

> server_auth@0.0.0 start /home/rafase282/Workspace/Pairing/podio-js/examples/server_auth
> node ./bin/www

module.js:472
    throw err;
    ^

Error: Cannot find module 'lodash'
    at Function.Module._resolveFilename (module.js:470:15)
    at Function.Module._load (module.js:418:25)
    at Module.require (module.js:498:17)
    at require (internal/module.js:20:19)
    at Object.<anonymous> (/home/rafase282/Workspace/Pairing/podio-js/lib/podio-js.js:3:9)
    at Module._compile (module.js:571:32)
    at Object.Module._extensions..js (module.js:580:10)
    at Module.load (module.js:488:32)
    at tryModuleLoad (module.js:447:12)
    at Function.Module._load (module.js:439:3)

npm ERR! Linux 4.8.0-42-generic
npm ERR! argv "/home/rafase282/.nvm/versions/node/v7.6.0/bin/node" "/home/rafase282/.nvm/versions/node/v7.6.0/bin/npm" "start"
npm ERR! node v7.6.0
npm ERR! npm  v4.1.2
npm ERR! code ELIFECYCLE
npm ERR! server_auth@0.0.0 start: `node ./bin/www`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the server_auth@0.0.0 start script 'node ./bin/www'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the server_auth package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node ./bin/www
npm ERR! You can get information on how to open an issue for this project with:
npm ERR!     npm bugs server_auth
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!     npm owner ls server_auth
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!     /home/rafase282/Workspace/Pairing/podio-js/examples/server_auth/npm-debug.log
rafase282@rafase282-Lenovo-Z70-80:~/Workspace/Pairing/podio-js/examples/server_auth$ 

I tried installing lodash and I still get the same error.

Rafase282 commented 7 years ago

I figured out the issue, it used the podio-js from the repo so I have to do npm install there first.