Jopyth/MMM-Remote-Control

"Not initialized"

Closed this issue · 4 comments

For a reason I can't comprehend I'm getting an error every time I want to edit display options
{ "success": false, "status": "error", "reason": "unknown", "info": "Not initialized, have you opened or refreshed your browser since the last time you started MagicMirror?" }
This happens every time, from a mobile and a loptop, with different browsers, also with fresh instances of the browser.

My config is standard:
{ module: 'MMM-Remote-Control', // uncomment the following line to show the URL of the remote control on the mirror // position: 'bottom_left', // you can hide this module afterwards from the remote control itself config: { customCommand: {}, // Optional, See "Using Custom Commands" below customMenu: "custom_menu.json", // Optional, See "Custom Menu Items" below showModuleApiMenu: true, // Optional, Enable the Module Controls menu apiKey: 'xxxxxxxxxxxxxxxxxxxxxx' // Optional, See API/README.md for details } }

Have not seen this message a few months ago and I have not changed anything in whitelisting:
ipWhitelist: [],

Using npm start dev I got an error:
TypeError: Cannot read property 'length' of undefined at Class.saveDefaultSettings (/home/pi/MagicMirror/modules/MMM-Remote-Control/node_helper.js:897:44) at Object.callback (/home/pi/MagicMirror/modules/MMM-Remote-Control/node_helper.js:679:56) at Object.run (/home/pi/MagicMirror/modules/MMM-Remote-Control/node_helper.js:547:26) at Timeout._onTimeout (/home/pi/MagicMirror/modules/MMM-Remote-Control/node_helper.js:555:28) at ontimeout (timers.js:427:11) at tryOnTimeout (timers.js:289:5) at listOnTimeout (timers.js:252:5) at Timer.processTimers (timers.js:212:10)

The reported line is:
for (var k = 0; k < moduleData.length; k++) {

So the variable moduleData in node_helper.js is undefined.

Actually I recently solved the issue and was just going back in to comment the answer. What happened for me anyway is that I was using a module that was not compatible with remote control, I believe it was MMM-HappyHour, but after I removed this from the confit the remote control worked again.

I would recommend deleting any more or less sketchy modules from your config and trying it out, it’s what worked for me.

I still do get this error sometimes, but I refresh the browser and it goes away.

Hey! So actually, I'm unable to reproduce this bug. You guys still having this issue?

jitmo commented

TL;DR, you might need to upgrade to at least MagicMirror 2.12.0 (released on 2020-07-01)

Detail: I have just encountered this issue and found the following in the web browser console (by browsing to http://YOUR_MIRROR_IP_ADDRESS:8080):

Load script: modules/MMM-Remote-Control//MMM-Remote-Control.js
module.js:471 Check MagicMirror version for module 'MMM-Remote-Control' - Minimum version:  2.12.0 - Current version: 2.11.0
module.js:475 Version is incorrect. Skip module: 'MMM-Remote-Control'