Error Message - reddit / bbs ---------------------------------------------------------------------- snoozerd · 2023-07-09 00:57 // Parse the JSON response. var cu = JSON.parse(current); // Check if the JSON is properly formatted. The "response" should wrap the entire object. if (cu.hasOwnProperty("response") ) { // Check if the response contains an error message. If so, log the error and exit. if (cu["response"].hasOwnProperty("error")) { var errtype = cu["response"]["error"]["type"]; var errdesc = cu["response"]["error"]["description"]; log("ERROR in weather.js: api.wunderground.com returned a '" + errtype + "' error with this description: '" + errdesc + "'."); log(LOG_DEBUG,"DEBUG for weather.js. API call looked like this at time of error: " + "http://api.wunderground.com/api/" + wungrndAPIkey + "/conditions/forecast/astronomy/alerts/q/" + wungrndQuery); log(LOG_DEBUG,"DEBUG for weather.js. The user.connection object looked like this at the time of error: " + user.connection); log(LOG_DEBUG,"DEBUG for weather.js. The dialup variable looked like this at the time of error: " + dialup); console.center("There was a problem getting data from Weather Underground."); console.center("The sysop has been notified."); console.pause(); exit(); } Error: !JavaScript weather.js line 103: SyntaxError: JSON.parse ​ ​ ---------------------------------------------------------------------- PraiseBobSlackOff · 2023-07-09 02:01 Check line 103 in weather.js. Looks like a syntax error with JSON.parse 🤷 ---------------------------------------------------------------------- electronicchicken · 2023-07-09 02:37 The script received a bad JSON response that it can't parse and isn't handing it gracefully. The reason for the bad response is likely the fact that weather underground discontinued its free API years ago and the URL being called by the script is not responding with the expected data anymore. There are probably some alternative weather scripts you could use. ---------------------------------------------------------------------- Send_IT_to_David · 2023-07-09 04:06 Right on ---------------------------------------------------------------------- banksy_h8r · 2023-07-09 05:20 Put `console.log(current)` right before the `JSON.parse` line and try again. Then check the console. You'll find malformed JSON there which should help you narrow it down. It's probably not even close to JSON at all, and instead a plain string saying something like "404 not found".