node-sonos-http-api: Problem running node sonos http api on Synology NAS

OK so I have followed the instructions and it seems I am still getting errors. I have installed node.js package from Synology (node -v v0.12.6). DS415+ Brand new Echo:-(

Looking at some of the post am I suppose assume that it will not work because of the node version? Node v4.x.x is needed? Below is my output - can anyone tell me what I have wrong?

WEST-NET1> npm install --production npm WARN package.json sonos-http-api@0.17.0 No license field. WEST-NET1> npm start

sonos-http-api@0.17.0 start /node-sonos-http-api-master node server.js

no settings file found, will only use default settings http server listening on port 5005 module.js:489 throw err; ^ SyntaxError: /node-sonos-http-api-master/presets.json: Unexpected token < at Object.parse (native) at Object.Module._extensions…json (module.js:486:27) at Module.load (module.js:355:32) at Function.Module._load (module.js:310:12) at Module.require (module.js:365:17) at require (module.js:384:17) at /node-sonos-http-api-master/lib/actions/preset.js:32:17 at FSReqWrap.cb as oncomplete

npm ERR! Linux 3.10.35 npm ERR! argv “/usr/bin/node” “/usr/bin/npm” “start” npm ERR! node v0.12.6 npm ERR! npm v2.11.2 npm ERR! code ELIFECYCLE npm ERR! sonos-http-api@0.17.0 start: node server.js npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the sonos-http-api@0.17.0 start script ‘node server.js’. npm ERR! This is most likely a problem with the sonos-http-api package, npm ERR! not with npm itself. npm ERR! Tell the author that this fails on your system: npm ERR! node server.js npm ERR! You can get their info via: npm ERR! npm owner ls sonos-http-api npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request: npm ERR! /node-sonos-http-api-master/npm-debug.log WEST-NET1>

About this issue

  • Original URL
  • State: closed
  • Created 9 years ago
  • Comments: 15 (4 by maintainers)

Most upvoted comments

Error: Cannot find module ./. resolveFilename-Error on Synology-NAS On Synology DS415+ I figured out, that the problem “Error: Cannot find module ‘/…/node-sonos-http/lib/actions/’ at Function.Module._resolveFilename (module.js…)” is caused by hidden directories that are created by an indexing service of the NAS. The .js-modules tries to enumerate all files in a directory - but on Synology hidden subdirectories cause the routine to fail. The directories start with the @-sign e.g. @eaDir. Deleting the directory (and subdirectories) solved my problems completely!