hassio-addons / addon-node-red

Node-RED - Home Assistant Community Add-ons
https://addons.community
MIT License
525 stars 120 forks source link

Node red won't start since 0.92.0 npm ERR! file /config/node-red/package.json #212

Closed StyxyDog closed 5 years ago

StyxyDog commented 5 years ago

Problem/Motivation

(Why the issue was filed) Node-RED will not start since recent upgrade.

Expected behavior

(What you expected to happen) Node-RED started previously but today after upgrading to hassio 0.92.0 and node-RED 3.03

Actual behavior

(What actually happened)

I see this error in the log

[s6-init] making user provided files available at /var/run/s6/etc...exited 0. [s6-init] ensuring user provided files have correct perms...exited 0. [fix-attrs.d] applying ownership & permissions fixes... [fix-attrs.d] done. [cont-init.d] executing container initialization scripts... [cont-init.d] 00-banner.sh: executing...

Hass.io Add-on: Node-RED Flow-based programming for the Internet of Things

Add-on version: 3.0.3 You are running the latest version of this add-on. System: HassOS 2.11 (armv7 / raspberrypi3) Home Assistant version: 0.92.0 Supervisor version: 162

Please, share the above information when looking for help or support in, e.g., GitHub, forums or the Discord chat.

[cont-init.d] 00-banner.sh: exited 0. [cont-init.d] 01-log-level.sh: executing... [cont-init.d] 01-log-level.sh: exited 0. [cont-init.d] nginx.sh: executing... [cont-init.d] nginx.sh: exited 0. [cont-init.d] node-red.sh: executing... [18:47:59] INFO: Password is NOT in the Have I Been Pwned database! Nice! [18:48:00] INFO: Password is NOT in the Have I Been Pwned database! Nice! npm ERR! file /config/node-red/package.json npm ERR! code EJSONPARSE npm ERR! JSON.parse Failed to parse json npm ERR! JSON.parse Unexpected token � in JSON at position 0 while parsing near '��������������������...' npm ERR! JSON.parse Failed to parse package.json data. npm ERR! JSON.parse package.json must be actual JSON, not just JavaScript. npm ERR! A complete log of this run can be found in: npm ERR! /root/.npm/_logs/2019-04-25T17_48_03_960Z-debug.log [18:48:04] FATAL: Failed un-installing conflicting packages [cont-init.d] node-red.sh: exited 1. [cont-finish.d] executing container finish scripts... [cont-finish.d] 99-message.sh: executing...

            Oops! Something went wrong.

We are so sorry, but something went terribly wrong when starting or running this add-on.

Be sure to check the log above, line by line, for hints.

[cont-finish.d] 99-message.sh: exited 0. [cont-finish.d] done. [s6-finish] waiting for services. [s6-finish] sending all processes the TERM signal.

Steps to reproduce

(How can someone else make/see it happen) I tried restoring node-red from earlier version snapshot, but the error is the same so I think something in 0.92.0 caused the problem.

Proposed changes

(If you have a proposed change, workaround or fix, describe the rationale behind it)

addons-assistant[bot] commented 5 years ago

:wave: Thanks for opening your first issue here! If you're reporting a :bug: bug, please make sure you include steps to reproduce it. Also, logs, error messages and information about your hardware might be usefull.

frenck commented 5 years ago

There is an error in one of your own config files:

/config/node-red/package.json

StyxyDog commented 5 years ago

Thank you, I'll look at that. I wasn't aware of that file before.

StyxyDog commented 5 years ago

Restored hassio to 0.91.4 re-upgraded and re-upgraded node-red addon - all good. I'll put that one down to luck! Thanks

addons-assistant[bot] commented 5 years ago

This thread has been automatically locked because it has not had recent activity. Please open a new issue for related bugs and link to relevant comments in this thread.