oveddan / posenet-for-installations

Provides an ideal way to use PoseNet for installations; it works offline and broadcasts poses over websocket.
Apache License 2.0
132 stars 29 forks source link

Server trouble on OSX #11

Closed chris-rogers-anki closed 5 years ago

chris-rogers-anki commented 5 years ago

I can run the app, however there does not seem to be a server running websockets on localhost:8080

App.tsx:252 WebSocket connection to 'ws://localhost:8080/' failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED

I can run other servers and access them through localhost.

error message:

0 verbose lifecycle posenet-for-installations@1.0.0~start-server: CWD: /Users/chris.rogers/workspace/posenet-for-installations
11 silly lifecycle posenet-for-installations@1.0.0~start-server: Args: [ '-c', 'cd server && npm start' ]
12 silly lifecycle posenet-for-installations@1.0.0~start-server: Returned: code: 1  signal: null
13 info lifecycle posenet-for-installations@1.0.0~start-server: Failed to exec start-server script
14 verbose stack Error: posenet-for-installations@1.0.0 start-server: `cd server && npm start`
14 verbose stack Exit status 1
14 verbose stack     at EventEmitter.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:301:16)
14 verbose stack     at EventEmitter.emit (events.js:182:13)
14 verbose stack     at ChildProcess.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
14 verbose stack     at ChildProcess.emit (events.js:182:13)
14 verbose stack     at maybeClose (internal/child_process.js:978:16)
14 verbose stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:265:5)
15 verbose pkgid posenet-for-installations@1.0.0
16 verbose cwd /Users/chris.rogers/workspace/posenet-for-installations
17 verbose Darwin 17.7.0
18 verbose argv "/usr/local/Cellar/node/11.3.0_1/bin/node" "/usr/local/bin/npm" "run" "start-server" "-l"
19 verbose node v11.3.0
20 verbose npm  v6.4.1
21 error code ELIFECYCLE
22 error errno 1
23 error posenet-for-installations@1.0.0 start-server: `cd server && npm start`
23 error Exit status 1
24 error Failed at the posenet-for-installations@1.0.0 start-server script.
24 error This is probably not a problem with npm. There is likely additional logging output above.
chris-rogers-anki commented 5 years ago

when i run "cd server && npm start" I get:

Error: Cannot find module '/Users/chris.rogers/workspace/posenet-for-installations/server/dist/index.js'

[Node]     at Function.Module._resolveFilename (internal/modules/cjs/loader.js:603:15)
[Node]     at Function.Module._load (internal/modules/cjs/loader.js:529:25)
[Node]     at Function.Module.runMain (internal/modules/cjs/loader.js:775:12)
[Node]     at startup (internal/bootstrap/node.js:300:19)
[Node]     at bootstrapNodeJSCore (internal/bootstrap/node.js:826:3)
[Node] npm ERR! code ELIFECYCLE
[Node] npm ERR! errno 1
[Node] npm ERR! posenet-offline-websocket-app@1.0.0 serve: `node ./dist/index.js`
[Node] npm ERR! Exit status 1
[Node] npm ERR! 
[Node] npm ERR! Failed at the posenet-offline-websocket-app@1.0.0 serve script.
chris-rogers-anki commented 5 years ago

running "yarn build" fixed it.