I am using a Raspberry Pi 3B and have set up the basic configuration of Magic Mirror.
I have then gone to activate the Weather module by adding the API Key and when I restart MagicMirror I get the following Syntax Error error message in the Terminal.
Config.js (File details
{
module: "MMM-OpenmapWeather",
position: "top_left", // This can be any of the regions. Best results in left or right regions.
header: "Current Weather", //Location is the default value if header is empty or not defined.
config: {
// See 'Configuration options' for more information.
location: "Phoenix,USA",
locationID: "", //Location ID from http://openweathermap.org/help/city_list.txt
appid: "120e565fba4c2008908c1c2ec957140c", //openweathermap.org API key
colorIcon: true
}
}
Terminal Syntax Error
SyntaxError: Unexpected token '{'
at internalCompileFunction (node:internal/vm:73:18)
at wrapSafe (node:internal/modules/cjs/loader:1160:20)
at Module._compile (node:internal/modules/cjs/loader:1212:27)
at Module._extensions..js (node:internal/modules/cjs/loader:1311:10)
at Module.load (node:internal/modules/cjs/loader:1098:32)
at Module._load (node:internal/modules/cjs/loader:945:12)
at c._load (node:electron/js2c/node_init:2:13672)
at Module.require (node:internal/modules/cjs/loader:1122:19)
at require (node:internal/modules/helpers:130:18)
at loadConfig (/home/synint/MagicMirror/js/app.js:117:14)
at App.start (/home/synint/MagicMirror/js/app.js:250:18)
at Object.<anonymous> (/home/synint/MagicMirror/js/electron.js:193:7)
at Module._compile (node:internal/modules/cjs/loader:1256:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1311:10)
at Module.load (node:internal/modules/cjs/loader:1098:32)
at Module._load (node:internal/modules/cjs/loader:945:12)
[2024-04-07 14:26:23.100] [LOG] Loading module helpers ...
[2024-04-07 14:26:23.821] [LOG] Initializing new module helper ...
[2024-04-07 14:26:23.823] [LOG] Module helper loaded: updatenotification
[2024-04-07 14:26:23.825] [LOG] No helper found for module: helloworld.
[2024-04-07 14:26:23.828] [LOG] All module helpers loaded.
[2024-04-07 14:26:23.847] [LOG] Starting server on port 8080 ...
[2024-04-07 14:26:39.288] [LOG] Server started ...
[2024-04-07 14:26:39.329] [LOG] Connecting socket for: updatenotification
[2024-04-07 14:26:39.331] [LOG] Starting module helper: updatenotification
[2024-04-07 14:26:39.333] [LOG] Sockets connected & modules started ...
[2024-04-07 14:26:46.150] [LOG] Launching application.
[2024-04-07 14:27:14.406] [INFO] System information:
### SYSTEM: manufacturer: Raspberry Pi Foundation; model: Raspberry Pi 3 Model B Plus Rev 1.3; raspberry: [object Object]; virtual: false
### OS: platform: linux; distro: Raspbian GNU/Linux; release: 11; arch: arm; kernel: 6.1.21-v7+
### VERSIONS: electron: 29.1.6; used node: 20.9.0; installed node: 21.7.1; npm: 10.5.0; pm2: 5.3.1
### OTHER: timeZone: Europe/London; ELECTRON_ENABLE_GPU: undefined
[7961:0407/142804.045780:ERROR:atom_cache.cc(229)] Add WM_CHANGE_STATE to kAtomsToCache
^C/home/synint/MagicMirror/node_modules/electron/dist/electron exited with signal SIGINT
synint@raspberrypi:~/MagicMirror $
Any help or guidance would be appreciated.
Cheers,
John