Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

examples from getting started docs fail to start #371

Closed
seansfkelley opened this issue May 11, 2020 · 4 comments
Closed

examples from getting started docs fail to start #371

seansfkelley opened this issue May 11, 2020 · 4 comments
Assignees

Comments

@seansfkelley
Copy link

seansfkelley commented May 11, 2020

Following the instructions at https://tableau.github.io/webdataconnector/docs/, npm start explodes.

npm start errors
> webdataconnector@2.0.0 start /Users/seankelley/code/webdataconnector                            
> node node_modules/npm-run-all/bin/npm-run-all --parallel corsproxy http-server
                                                    
                                                                                                        
> webdataconnector@2.0.0 http-server /Users/seankelley/code/webdataconnector
> node node_modules/http-server/bin/http-server -p 8888 -c-1
                                                    
                                                                                                        
> webdataconnector@2.0.0 corsproxy /Users/seankelley/code/webdataconnector
> export CORSPROXY_PORT=8889 || set CORSPROXY_PORT=8889 && node node_modules/corsproxy/bin/corsproxy
                                                    
Starting up http-server, serving ./
Available on:
  http://127.0.0.1:8888
  http://192.168.1.49:8888
Hit CTRL-C to stop the server
/Users/seankelley/code/webdataconnector/node_modules/hapi/lib/defaults.js:49
            uploads: Os.tmpDir(),
                        ^

TypeError: Os.tmpDir is not a function
    at Object.<anonymous> (/Users/seankelley/code/webdataconnector/node_modules/hapi/lib/defaults.js:49:25)
    at Module._compile (internal/modules/cjs/loader.js:1176:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1196:10)
    at Module.load (internal/modules/cjs/loader.js:1040:32)
    at Function.Module._load (internal/modules/cjs/loader.js:929:14)
    at Module.require (internal/modules/cjs/loader.js:1080:19)
    at require (internal/modules/cjs/helpers.js:72:18)
    at Object.<anonymous> (/Users/seankelley/code/webdataconnector/node_modules/hapi/lib/route.js:9:16)
    at Module._compile (internal/modules/cjs/loader.js:1176:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1196:10)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! webdataconnector@2.0.0 corsproxy: `export CORSPROXY_PORT=8889 || set CORSPROXY_PORT=8889 && node node_modules/corsproxy/bin/corsproxy`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the webdataconnector@2.0.0 corsproxy script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/seankelley/.npm/_logs/2020-05-11T18_07_59_484Z-debug.log
http-server stopped.
ERROR: "corsproxy" exited with 1.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! webdataconnector@2.0.0 start: `node node_modules/npm-run-all/bin/npm-run-all --parallel corsproxy http-server`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the webdataconnector@2.0.0 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/seankelley/.npm/_logs/2020-05-11T18_07_59_574Z-debug.log
/Users/seankelley/.npm/_logs/2020-05-11T18_07_59_574Z-debug.log
0 info it worked if it ends with ok
1 verbose cli [
1 verbose cli   '/usr/local/Cellar/node/14.2.0/bin/node',
1 verbose cli   '/usr/local/bin/npm',
1 verbose cli   'start'
1 verbose cli ]
2 info using npm@6.14.4
3 info using node@v14.2.0
4 verbose run-script [ 'prestart', 'start', 'poststart' ]
5 info lifecycle webdataconnector@2.0.0~prestart: webdataconnector@2.0.0
6 info lifecycle webdataconnector@2.0.0~start: webdataconnector@2.0.0
7 verbose lifecycle webdataconnector@2.0.0~start: unsafe-perm in lifecycle true
8 verbose lifecycle webdataconnector@2.0.0~start: PATH: /usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/Users/seankelley/code/webdataconnector/node_modules/.bin:/Users/seankelley/.pyenv/shims:/usr/local/bin:/Users/seankelley/.poetry/bin:/Users/seankelley/.cargo/bin:/Users/seankelley/.local/bin:/usr/local/sbin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/Users/seankelley/.pyenv/shims:/Users/seankelley/.antigen/bundles/robbyrussell/oh-my-zsh/lib:/Users/seankelley/.antigen/bundles/robbyrussell/oh-my-zsh/plugins/command-not-found:/Users/seankelley/.antigen/bundles/robbyrussell/oh-my-zsh/plugins/npm:/Users/seankelley/.antigen/bundles/robbyrussell/oh-my-zsh/plugins/tmuxinator:/Users/seankelley/.antigen/bundles/robbyrussell/oh-my-zsh/plugins/yarn:/Users/seankelley/.antigen/bundles/robbyrussell/oh-my-zsh/plugins/git:/Users/seankelley/.antigen/bundles/zsh-users/zsh-syntax-highlighting
9 verbose lifecycle webdataconnector@2.0.0~start: CWD: /Users/seankelley/code/webdataconnector
10 silly lifecycle webdataconnector@2.0.0~start: Args: [
10 silly lifecycle   '-c',
10 silly lifecycle   'node node_modules/npm-run-all/bin/npm-run-all --parallel corsproxy http-server'
10 silly lifecycle ]
11 silly lifecycle webdataconnector@2.0.0~start: Returned: code: 1  signal: null
12 info lifecycle webdataconnector@2.0.0~start: Failed to exec start script
13 verbose stack Error: webdataconnector@2.0.0 start: `node node_modules/npm-run-all/bin/npm-run-all --parallel corsproxy http-server`
13 verbose stack Exit status 1
13 verbose stack     at EventEmitter.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:332:16)
13 verbose stack     at EventEmitter.emit (events.js:315:20)
13 verbose stack     at ChildProcess.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
13 verbose stack     at ChildProcess.emit (events.js:315:20)
13 verbose stack     at maybeClose (internal/child_process.js:1051:16)
13 verbose stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:287:5)
14 verbose pkgid webdataconnector@2.0.0
15 verbose cwd /Users/seankelley/code/webdataconnector
16 verbose Darwin 18.7.0
17 verbose argv "/usr/local/Cellar/node/14.2.0/bin/node" "/usr/local/bin/npm" "start"
18 verbose node v14.2.0
19 verbose npm  v6.14.4
20 error code ELIFECYCLE
21 error errno 1
22 error webdataconnector@2.0.0 start: `node node_modules/npm-run-all/bin/npm-run-all --parallel corsproxy http-server`
22 error Exit status 1
23 error Failed at the webdataconnector@2.0.0 start script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1, true ]

I'm guessing this has something to do with the 145 vulnerabilities (including 2 critical)/dozens of deprecations (including a few that outright state they are unsupported)/missing peer dependencies mentioned on install.

npm install errors
npm WARN deprecated babel-preset-es2015@6.24.1: 🙌  Thanks for using Babel: we recommend using babel-preset-env now: please read babeljs.io/env to update!                                                      
npm WARN deprecated vis@4.21.0: Please consider using https://github.com/visjs                                                                                                                                  
npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
npm WARN deprecated jade@0.26.3: Jade has been renamed to pug, please install the latest version of pug instead of jade
npm WARN deprecated to-iso-string@0.0.2: to-iso-string has been deprecated, use @segment/to-iso-string instead.
npm WARN deprecated formatio@1.1.1: This package is unmaintained. Use @sinonjs/formatio instead
npm WARN deprecated ecstatic@1.4.1: https://github.com/jfhbrook/node-ecstatic/issues/259
npm WARN deprecated good@6.6.3: This module has moved and is now available at @hapi/good. Please update your dependencies as this version is no longer maintained an may contain bugs and security issues.
npm WARN deprecated good-console@5.3.2: This module has moved and is now available at @hapi/good-console. Please update your dependencies as this version is no longer maintained an may contain bugs and security issues.
npm WARN deprecated hapi@9.5.1: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated inert@3.2.1: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated vision@3.0.0: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated h2o2@4.0.2: This module has moved and is now available at @hapi/h2o2. Please update your dependencies as this version is no longer maintained an may contain bugs and security issues.
npm WARN deprecated core-js@2.6.11: core-js@<3 is no longer maintained and not recommended for usage due to the number of issues. Please, upgrade your dependencies to the actual version of core-js@3.
npm WARN deprecated minimatch@0.3.0: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue
npm WARN deprecated items@1.1.1: This module has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version of hapi to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated joi@6.10.1: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated good-squeeze@2.1.0: This module has moved and is now available at @hapi/good-squeeze. Please update your dependencies as this version is no longer maintained an may contain bugs and security issues.
npm WARN deprecated wreck@6.3.0: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated accept@1.1.0: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated call@2.0.2: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated ammo@1.0.1: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated catbox@6.0.0: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated catbox-memory@1.1.2: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated heavy@3.0.1: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated iron@2.1.3: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated kilt@1.1.1: This module is no longer maintained.
npm WARN deprecated peekaboo@1.0.0: This module is no longer maintained.
npm WARN deprecated mimos@2.0.2: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated statehood@2.1.1: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated shot@1.7.0: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated topo@1.1.0: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated subtext@2.0.2: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated fsevents@1.2.13: fsevents 1 will break on node v14+ and could be using insecure binaries. Upgrade to fsevents 2.
npm WARN deprecated content@1.0.2: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated pez@1.0.0: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated b64@2.0.1: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated nigel@1.0.1: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated vise@1.0.0: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated boom@2.9.0: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated cryptiles@2.0.5: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated hoek@2.16.3: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated items@1.1.0: This module has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version of hapi to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated joi@6.8.1: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated subtext@2.0.0: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).
npm WARN deprecated wreck@6.2.0: This version has been deprecated in accordance with the hapi support policy (hapi.im/support). Please upgrade to the latest version to get the best features, bug fixes, and security patches. If you are unable to upgrade at this time, paid support is available for older versions (hapi.im/commercial).

> ejs@2.7.4 postinstall /Users/seankelley/code/webdataconnector/node_modules/ejs
> node ./postinstall.js

Thank you for installing EJS: built with the Jake JavaScript build tool (https://jakejs.com/)

npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN eslint-config-airbnb@9.0.1 requires a peer of eslint@^2.9.0 but none is installed. You must install peer dependencies yourself.
npm WARN eslint-plugin-import@1.16.0 requires a peer of eslint@2.x - 3.x but none is installed. You must install peer dependencies yourself.
npm WARN eslint-plugin-jsx-a11y@1.5.5 requires a peer of eslint@^2.10.2 || 3.x but none is installed. You must install peer dependencies yourself.
npm WARN ajv-keywords@2.1.1 requires a peer of ajv@^5.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN eslint-config-airbnb-base@3.0.1 requires a peer of eslint@^2.9.0 but none is installed. You must install peer dependencies yourself.

added 151 packages from 76 contributors and audited 6022 packages in 12.022s

14 packages are looking for funding
  run `npm fund` for details

found 145 vulnerabilities (22 low, 92 moderate, 29 high, 2 critical)
  run `npm audit fix` to fix them, or `npm audit` for details

I'm on macOS 10.14.6 and Node 14.2.0 with npm 6.14.4 (installed from Homebrew).

@seansfkelley
Copy link
Author

hapi is being pulled in by corsproxy, which is very dead. hapi uses a deprecated call to os.tmpDir, which was changed in 2016.

However, using npm run http-server instead of npm start, which will bypass the usages of corsproxy, seems to more or less work?

@weissleb
Copy link
Contributor

As @seansfkelley mentions, npm run http-server appears to work, but doesn't feel great for node noobs.

@martimors
Copy link

@seansfkelley That works, but no static assets can be found. Seems like the url is interpreting the name of a function as a string or something?
image
Running npm 6.14.8 and node 14.10.1 on Ubuntu 20.04.

@KeshiaRose
Copy link
Contributor

Hi @seansfkelley & @dingobar, I believe this is because of your version of Node. I just did a fresh install on macOS 10.15.7 with node 12.19.0 and npm 6.14.8 and while I did get the plethora of warnings the Simulator ran smoothly. When I switch to node 14.14.0 it doesn't run at all (due to the issues with hapi @seansfkelley pointed out). Using npm run http-server is your best bet for right now. As for the missing assets those are for the GitHub Jekyll pages and not necessary to run the Simulator.
-Keshia

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants