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

Cannot start node-red in local environment #26

Open
rophy opened this issue Aug 15, 2018 · 0 comments
Open

Cannot start node-red in local environment #26

rophy opened this issue Aug 15, 2018 · 0 comments

Comments

@rophy
Copy link

rophy commented Aug 15, 2018

version: 0.8.0

> npm start

> [email protected] start R:\Downloads\node-red-bluemix-starter-master
> node --max-old-space-size=160 index.js --settings ./bluemix-settings.js -v

15 Aug 16:19:19 - Starting Node-RED on IBM Cloud bootstrap
15 Aug 16:19:19 - Loading bluemix-settings.js
15 Aug 16:19:19 - Failed to find Cloudant service: /^node-red-bluemix-starter.cloudantNoSQLDB/
15 Aug 16:19:20 - Loading application settings
R:\Downloads\node-red-bluemix-starter-master\node_modules\node-red\red\runtime\storage\localfilesystem\projects\index.js:45
    log = runtime.log;
                  ^

TypeError: Cannot read property 'log' of undefined
    at Object.init (R:\Downloads\node-red-bluemix-starter-master\node_modules\node-red\red\runtime\storage\localfilesystem\projects\index.js:45:19)
    at Object.init (R:\Downloads\node-red-bluemix-starter-master\node_modules\node-red\red\runtime\storage\localfilesystem\index.js:62:32)
    at Object.<anonymous> (R:\Downloads\node-red-bluemix-starter-master\index.js:36:13)
    at Module._compile (module.js:652:30)
    at Object.Module._extensions..js (module.js:663:10)
    at Module.load (module.js:565:32)
    at tryModuleLoad (module.js:505:12)
    at Function.Module._load (module.js:497:3)
    at Function.Module.runMain (module.js:693:10)
    at startup (bootstrap_node.js:191:16)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] start: `node --max-old-space-size=160 index.js --settings ./bluemix-settings.js -v`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] 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!     D:\Users\rophy\npm-cache\_logs\2018-08-15T08_19_20_549Z-debug.log

Fix: in index.js36::

    storage.init(settings).then(storage.getSettings).then(function(runtimeSettings) {

Change the line to:

    storage.init(settings, require('./node_modules/node-red/red/runtime')).then(storage.getSettings).then(function(runtimeSettings) {

Seems to make the error gone, but I'm not sure if it is the right thing to do.

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

1 participant