MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    1. Home
    2. Jarhead96097
    3. Posts
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.
    Offline
    • Profile
    • Following 0
    • Followers 0
    • Topics 5
    • Posts 34
    • Groups 0

    Posts

    Recent Best Controversial
    • RE: Default Weather module still not displaying

      @sdetweil Sam, thanks for all of your help. I’ve finished rebuilding without running ‘npm audit fix’ and everything is working as it should! I used your installation script and everything worked fine. I also took the opportunity to move things around and try a couple of new 3rd party modules… everything is back to normal!

      Thanks again,
      Jarhead96097

      posted in Troubleshooting
      Jarhead96097J
      Jarhead96097
    • RE: Default Weather module still not displaying

      @sdetweil here is what my weather.js (newly rebuilt, but not yet configured) has on lines 148 to 166:

      	// What to do when the weather provider has new information available?
      	updateAvailable: function () {
      		Log.log("New weather information available.");
      		this.updateDom(0);
      		this.scheduleUpdate();
      
      		if (this.weatherProvider.currentWeather()) {
      			this.sendNotification("CURRENTWEATHER_TYPE", { type: this.weatherProvider.currentWeather().weatherType.replace("-", "_") });
      		}
      
      		const notificationPayload = {
      			currentWeather: this.weatherProvider?.currentWeatherObject?.simpleClone() ?? null,
      			forecastArray: this.weatherProvider?.weatherForecastArray?.map((ar) => ar.simpleClone()) ?? [],
      			hourlyArray: this.weatherProvider?.weatherHourlyArray?.map((ar) => ar.simpleClone()) ?? [],
      			locationName: this.weatherProvider?.fetchedLocationName,
      			providerName: this.weatherProvider.providerName
      		};
      		this.sendNotification("WEATHER_UPDATED", notificationPayload);
      	},
      
      posted in Troubleshooting
      Jarhead96097J
      Jarhead96097
    • RE: Default Weather module still not displaying

      @OldSunGuy I use the MMM-ModuleScheduler 3rd party module to control when my MM turns off everything except the clock and dims the display at night. “daytime_scheduler” is the class I used to turn off those modules at night.

      posted in Troubleshooting
      Jarhead96097J
      Jarhead96097
    • RE: Default Weather module still not displaying

      @sdetweil sorry, already using your installation script (but no “npm audit fix” this time around).

      posted in Troubleshooting
      Jarhead96097J
      Jarhead96097
    • RE: Default Weather module still not displaying

      @sdetweil “On branch master,” and up to date with origin/master. I also meant to reply earlier that this is on a RPI 4B. Unfortunately, still getting the same error and the weather module is not displaying information.

      I appreciate everyone’s time…but I’m going to cut to the chase and rebuild using your install script.

      Thanks again for the time, you’re always very helpful, and I appreciate it.

      posted in Troubleshooting
      Jarhead96097J
      Jarhead96097
    • RE: Default Weather module still not displaying

      @sdetweil Good to know…that may be the root cause of all of this. After rebuilding my MM on 2.20.0, I did the npm audit fix. If we can’t get to a resolution in the next few minutes, I’ll chalk this up to a learning experience and do another rebuild.

      posted in Troubleshooting
      Jarhead96097J
      Jarhead96097
    • RE: Default Weather module still not displaying

      @sdetweil Oh, okay. Let me try that updated string of commands…

      posted in Troubleshooting
      Jarhead96097J
      Jarhead96097
    • RE: Default Weather module still not displaying

      @sdetweil I added “npm audit fix” as there was 1 high severity vulnerability found. It didn’t solve the vulnerability (didn’t try “npm audit fix --force”), and I’m getting the same error.

      posted in Troubleshooting
      Jarhead96097J
      Jarhead96097
    • RE: Default Weather module still not displaying

      @sdetweil no luck. Still receiving the same error on line 159, and no display on the MM.

      posted in Troubleshooting
      Jarhead96097J
      Jarhead96097
    • RE: Default Weather module still not displaying

      @sdetweil thanks… Well, no change. I’ve tried that and also copied the portion of the weather module from the original config.js, which was renamed as config.js.sample during setup. Both attempts still result in the Unexpected Syntax Error: Unexpected token message coming from line 159 of weather.js.

      You’re always very helpful, thanks for your time. Any other ideas?

      posted in Troubleshooting
      Jarhead96097J
      Jarhead96097
    • 1
    • 2
    • 3
    • 4
    • 1 / 4