Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[QUESTION] Weather widget has error #577

Closed
vanillanesquik opened this issue Mar 25, 2022 · 3 comments
Closed

[QUESTION] Weather widget has error #577

vanillanesquik opened this issue Mar 25, 2022 · 3 comments

Comments

@vanillanesquik
Copy link

Hello,

I am having trouble with the weather widget, I was able to go through the configuration and setup all of my links and sections but I am trying to experiment with the widgets.

I was able to confirm that the basic widgets works (no API), for example the Crypto ones in the sample config.

I signed up for openweather.org and setup the widget in my config. I have tried several different city codes and switched to US just for troubleshooting.

I have tried with both the proxy (useProxy: true) and internal CORS (no proxy). I don't know how to access the logs to find out what the problem is. I only saw references to using the browser console which I do not have much experience with in troubleshooting.

Any idea where I may be able to find the logs?
I am running on Docker in Unraid. I have Pihole running on unraid and use PFsense on my router. Openweather.org and api.openweather.org are both pingable from inside the container.

image

  • name: Today
    displayData:
    rows: 5
    sortBy: default
    cols: 5
    collapsed: false
    hideForGuests: false
    widgets:
    - type: weather
    useProxy: true
    options: null
    apiKey: efdbade728b37086877a5e83442004db
    city: US
    units: imperial
    hideDetails: false
    id: 0_513_weather
@liss-bot

This comment was marked as off-topic.

@Lissy93
Copy link
Owner

Lissy93 commented Mar 26, 2022

Just open the console / usually F12

Looking at your example, I think city: us is probably not a valid city name, it has to be something supported by OWM.

Also, not sure if it's just the formatting in how you've pasted your config (you can use ``` <code> ``` for code blocks), but the indentation of your config looks incorrect. Don't set options to null, instead, you need to nest apiKey, city, units under options.

I updated your example, and this now works:

- name: Today
  displayData:
    rows: 5
    sortBy: default
    cols: 5
    collapsed: false
    hideForGuests: false
  widgets:
  - type: weather
    options:
      apiKey: efdbade728b37086877a5e83442004db
      city: New York City, US
      units: imperial

You can always run yarn validate-config if you're unsure.

For this widget, you shouldn't need the useProxy option, but this might depend on your setup.

Hope that helps :)

@vanillanesquik
Copy link
Author

Thank you! Resolved now, that worked!

@Lissy93 Lissy93 changed the title [QUESTION] [QUESTION] Weather widget has error May 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants