Read the statement by Michael Teeuw here.
node_helper.js is not working?
-
@sdetweil Apologies.
jackson@raspberrypi:~/Documents/MagicMirror/config $ ls -laF total 20 drwxr-xr-x 2 jackson jackson 4096 Feb 9 19:19 ./ drwxr-xr-x 18 jackson jackson 4096 Feb 2 10:27 ../ -rwxrwxrwx 1 root root 1998 Feb 9 19:19 config.js* -rw-r--r-- 1 jackson jackson 3534 Feb 2 10:27 config.js.sample -rw-r--r-- 1 jackson jackson 1024 Feb 2 12:12 .config.js.swp
-
change the permissions owner and group
exit the editorsudo chown jackson config.js
sudo chgrp jackson config.js -
@sdetweil Okay I ran both of those commands.
-
@vandy2424 and try starting mm again
-
@sdetweil The calendar module still says loading… Everything else is the same as it was. Both logs show exactly the same as well.
-
@vandy2424 can you confirm the permissions change?
ls -laF
I can explain it
access to the file fails at startup time
fs.accessSync() js/app.js, line 117
so defaults is used… thats node helpersfile is loaded in the browser anyhow(index.html), and that controls module loading in browser
-
@sdetweil I will test in the morning
-
@sdetweil Yeah sure, the output actually looks the same even though I ran those commands:
jackson@raspberrypi:~/Documents/MagicMirror/config $ ls -laF total 20 drwxr-xr-x 2 jackson jackson 4096 Feb 9 19:19 ./ drwxr-xr-x 18 jackson jackson 4096 Feb 2 10:27 ../ -rwxrwxrwx 1 jackson jackson 1998 Feb 9 19:19 config.js* -rw-r--r-- 1 jackson jackson 3534 Feb 2 10:27 config.js.sample -rw-r--r-- 1 jackson jackson 1024 Feb 2 12:12 .config.js.swp
And wow, its incredible you were able to find that. Thanks so much for the continuous help. Hopefully we are close!
-
@vandy2424 try this
sudo chmod 644 config.js
-
@vandy2424 said in node_helper.js is not working?:
Hopefully we are close!
I can recreate it if I force the fs api call to fail… but I cannot get it to fail normally
root, full permissions, still works…
i can force it to fail the accessSync()
with permissions 740, and owner/group as root
but, i get an error message in the npm startup messages
[09.02.2024 21:21.19.642] [DEBUG] config template file not exists, no envsubst [09.02.2024 21:21.19.642] [ERROR] WARNING! Could not load config file. Starting with default configuration. Error found: Error: EACCES: permission denied, open '/home/pi/Documents/MagicMirror/config/config.js'