Read the statement by Michael Teeuw here.
Weather module config
-
@sdetweil thanks. That got rid of the errors, now when I
npm startthe weather module seems to be just loading indefinitely. Any ideas? -
@mrlowndes did u get an apiid? ‘loading’ means waiting for data … so, the component getting the data did not succeed
npm start
then look at the messagesor possibly open the developers window (f12 or ctrl-shift-i) select the console tab, and scroll up looking for errors…
-
@mrlowndes said in Weather module config:
index):1 Refused to apply style from ‘http://localhost:8080/css/custom.css’ because its MIME type (‘text/html’) is not a supported stylesheet MIME type, and strict MIME checking is enabled.
ok, don’t know for the slow network.
but for this one
do
touch ~/MagicMirror/css/custom.css -
@sdetweil Thanks for the tip. The errors were at the bottom. This is what I found:
Failed to load resource: the server responded with a status of 400 () weathergov.js:55 Could not load data ... XMLHttpRequest weather.js:151 New weather information available. main.js:301 [Intervention] Slow network is detected. See https://www.chromestatus.com/feature/5636954674692096 for more details. Fallback font will be used while loading: http://localhost:8080/vendor/node_modules/weathericons/font/weathericons-regular-webfont.woff api.openweathermap.o…xxxxxxxxxxxxxxxx:1 Failed to load resource: the server responded with a status of 401 (Unauthorized) weatherforecast.js:266 weatherforecast: Your AppID does not support long term forecasts. Switching to fallback endpoint. (index):1 Refused to apply style from 'http://localhost:8080/css/custom.css' because its MIME type ('text/html') is not a supported stylesheet MIME type, and strict MIME checking is enabled -
@sdetweil do you know where I could get an appid for weathergov? The documentation for the module is very thin
-
no key required for that point… only works for US locations
-
@sdetweil Do you have any suggestions as to what I should try next?
-
@mrlowndes u can test that the api works from your location
put this in your browser
https://api.weather.gov/points/LAT,LON/forecastreplace the LAT,LON
by the values from the google maps (maps.google.com) of your location…
in the url, you will see two numbers xx.yyyyyy,-uu.zzzzzz
just cut/paste that whole set of numbers and paste over the LAT,LON (notice the comma comes with the numbers too) -
@sdetweil Thanks so much, the documentation doesn’t make that clear at all
-
@mrlowndes no, this is just a test… making sure the api would work as called by the module
-
@sdetweil yeah, no dice. This came up in my browser
"title": "Data Unavailable For Requested Point", "type": "https://api.weather.gov/problems/InvalidPoint", "status": 404, "detail": "Unable to provide data for requested point 34.5444,119.7913", "instance": "https://api.weather.gov/requests/8199fbe2-ac6c-4c7c-b109-ed162794f780" -
@mrlowndes as I said, only works for US locations
-
@sdetweil yeah, it is a US location
-
@mrlowndes how can +119 be US location , mine is minus 97 (west of london)
-
@sdetweil I’m using the lat long listed here: https://forecast.weather.gov/MapClick.php?lat=34.54167&lon=-119.80917#.XqhoOJp7kWr
-
@mrlowndes u forgot the - sign
34.5444,119.7913", -
@sdetweil haha well that was dumb of me. I copied it from the web page where there isn’t a minus, but in the URL there obviously is. Thanks so much! got it working!
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login