NicolasSiver / nodebb-plugin-ns-twitch-monitor

Monitors specific channels and adds them to widget view

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Plugin forced NodeBB to crash / restart - 3 times in a row

GitPuffy opened this issue · comments

This plugin works great, when it is working and works for periods of time without difficulties. Occasionally it throws fits. Recently the twitch-plugin caused my NodeBB to crash and restart three times in a row. I had logging enabled in my tmux session so I have the luxury of posting the crash / start messages. I am running NodeBB v1.0.2 and nodebb-plugin-ns-twitch-monitor version 3.0.4.

These are the errors:

5/8 00:14 [1270] - error: TypeError: Cannot call method 'forEach' of undefined
    at /usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:74:37
    at transform (/usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:89:25)
    at /usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:72:35
    at fn (/usr/share/nodebb/PRD/node_modules/async/lib/async.js:746:34)
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:1213:16
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:166:37
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:706:43
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:167:37
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:1209:30
    at /usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:48:13
TypeError: Cannot call method 'forEach' of undefined
    at /usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:74:37
    at transform (/usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:89:25)
    at /usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:72:35
    at fn (/usr/share/nodebb/PRD/node_modules/async/lib/async.js:746:34)
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:1213:16
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:166:37
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:706:43
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:167:37
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:1209:30
    at /usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:48:13
5/8 00:14 [1270] - info: [app] Shutdown (SIGTERM/SIGINT) Initialised.
5/8 00:14 [1270] - info: [app] Database connection closed.
5/8 00:14 [1270] - info: [app] Web server closed to connections.
5/8 00:14 [1270] - info: [app] Shutdown complete.
[cluster] Child Process (1270) has exited (code: 1, signal: null)
[cluster] Spinning up another process...

5/8 00:14 [1822] - info: Time: Fri Aug 05 2016 00:14:38 GMT-0600 (MDT)
5/8 00:14 [1822] - info: Initializing NodeBB v1.0.2
[...]
5/8 00:14 [1822] - warn: [plugins/twitch-monitor] Dispose Stream Manager
5/8 00:14 [1822] - info: [plugins/twitch-monitor] Start monitoring of channels, delay is 30000 ms
5/8 00:15 [1822] - error: TypeError: Cannot call method 'forEach' of undefined
    at /usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:74:37
    at transform (/usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:89:25)
    at /usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:72:35
    at fn (/usr/share/nodebb/PRD/node_modules/async/lib/async.js:746:34)
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:1213:16
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:166:37
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:706:43
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:167:37
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:1209:30
    at /usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:48:13
TypeError: Cannot call method 'forEach' of undefined
    at /usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:74:37
    at transform (/usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:89:25)
    at /usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:72:35
    at fn (/usr/share/nodebb/PRD/node_modules/async/lib/async.js:746:34)
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:1213:16
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:166:37
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:706:43
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:167:37
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:1209:30
    at /usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:48:13
5/8 00:15 [1822] - info: [app] Shutdown (SIGTERM/SIGINT) Initialised.
5/8 00:15 [1822] - info: [app] Database connection closed.
5/8 00:15 [1822] - info: [app] Web server closed to connections.
5/8 00:15 [1822] - info: [app] Shutdown complete.
[cluster] Child Process (1822) has exited (code: 1, signal: null)
[cluster] Spinning up another process...

5/8 00:15 [1844] - info: Time: Fri Aug 05 2016 00:15:26 GMT-0600 (MDT)
5/8 00:15 [1844] - info: Initializing NodeBB v1.0.2
[...]
5/8 00:15 [1844] - warn: [plugins/twitch-monitor] Dispose Stream Manager
5/8 00:15 [1844] - info: [plugins/twitch-monitor] Start monitoring of channels, delay is 30000 ms
5/8 00:16 [1844] - error: TypeError: Cannot call method 'forEach' of undefined
    at /usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:74:37
    at transform (/usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:89:25)
    at /usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:72:35
    at fn (/usr/share/nodebb/PRD/node_modules/async/lib/async.js:746:34)
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:1213:16
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:166:37
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:706:43
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:167:37
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:1209:30
    at /usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:48:13
TypeError: Cannot call method 'forEach' of undefined
    at /usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:74:37
    at transform (/usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:89:25)
    at /usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:72:35
    at fn (/usr/share/nodebb/PRD/node_modules/async/lib/async.js:746:34)
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:1213:16
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:166:37
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:706:43
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:167:37
    at /usr/share/nodebb/PRD/node_modules/async/lib/async.js:1209:30
    at /usr/share/nodebb/PRD/node_modules/nodebb-plugin-ns-twitch-monitor/plugin/twitch/api.js:48:13
5/8 00:16 [1844] - info: [app] Shutdown (SIGTERM/SIGINT) Initialised.
5/8 00:16 [1844] - info: [app] Database connection closed.
5/8 00:16 [1844] - info: [app] Web server closed to connections.
5/8 00:16 [1844] - info: [app] Shutdown complete.
[cluster] Child Process (1844) has exited (code: 1, signal: null)
[cluster] Spinning up another process...

5/8 00:16 [1865] - info: Time: Fri Aug 05 2016 00:16:15 GMT-0600 (MDT)
5/8 00:16 [1865] - info: Initializing NodeBB v1.0.2
[...]
5/8 00:16 [1865] - warn: [plugins/twitch-monitor] Dispose Stream Manager
5/8 00:16 [1865] - info: [plugins/twitch-monitor] Start monitoring of channels, delay is 30000 ms

If you used a twitch-monitor before v3.0.4 Try to re-install plugin from the scratch, I mean delete plugin data from the database. More details could be found on NodeBB forum in corresponding thread.

Re-open a ticket if plugin data removal doesn't help.