7 Day Weather Forecast

First of all you need to have dark sky enabled already.

configuration.yaml

homeassistant:
  packages: !include_dir_named packages
python_script: 

weather.yaml located at homeassistant/packages/weather.yaml
dark_sky_friendly_names.py located at homeassistant/python scripts/dark_sky_friendly_names.py
icon pictures located at homeassistant/www/dark_sky/all the ***.png (download https://www.dr-lex.be/software/download/DarkSky-icons.zip )

Secondly from your configuration.yaml the space and indent need to be corrected under homeassistant:
Copy from mine and paste to see the different. the problem on weather.yaml and configuration is the indent are incorrect.

homeassistant:
  name: <removed for privacy>
  latitude: <removed for privacy>
  longitude: <removed for privacy>
  elevation: <removed for privacy>
  unit_system: metric
  time_zone: Europe/London
  customize: !include customize.yaml
  packages: !include_dir_named packages

sensor:
  - platform: darksky
    api_key: <removed for privacy>
    forecast:
      - 1
      - 2
      - 3
      - 4
      - 5
      - 6
      - 7
    monitored_conditions:
      - summary
      - icon
      - precip_probability 
      - apparent_temperature 
      - wind_speed 
      - cloud_cover 
      - hourly_summary 
      - daily_summary 
      - temperature_max 
      - temperature_min

https://hastebin.com/bakezuniru.makefile - configuration.yaml

https://hastebin.com/aramequyuy.coffeescript - weather.yaml

https://hastebin.com/qufufofiro.coffeescript - dark_sky_friendly_names.py

My stuff is saved on:
\192.168.0.22\config\configuration.yaml
\192.168.0.22\config\packages\weather.yaml
\192.168.0.22\config\python_scripts\dark_sky_friendly_names.py
\192.168.0.22\config\www\dark_sky*.png

I am running Hass.IO 0.62.1 on a Raspberry Pi 3 board, my raspi has a static IP configured on my router, and I have duckdns setup with letsencrypt, I know that part is working because I can control my lights using Google Assistant addon which I was able to set up as normal.

The error logs tooā€¦

Sorry, here it is, from the ā€œcheck config buttonā€, if you need logs from another source please let me know.

https://hastebin.com/rotaqokoco.sql

I believe Iā€™ve got it enabledā€¦

I canā€™t find yours, where is it?

Your icons should be in \192.168.0.22\config\www\icons\dark_sky\dark_sky*.png.

Can you remove the automation once and just run the python_script from the dev tools?

Ok, Iā€™ve done that, moved the icons to that folder and also removed the automation block and restarted the server, now this is what I get, which is a good start:

How do I proceed from here?

Did you run the python_script from dev tools? That should rename all the entities.

No, just restarted the server. Right now Iā€™ve done developer tools > services > python_script.dark_sky_friendly_names > call service and got a message that the service was calledā€¦

Result is:

So the script works. The only thing missing is the automation. Are you using tab instead of spaces in the automation? Copy/paste the automation again.

No, I am using spaces. I am aware that tabs can break YAML. I use double spaces.

Iā€™m editing the code on Visual Studio Code.

Do you mean copy the automation section from your weather.yaml file on github and paste into my weather.yaml file? And then restart?

you checked those errors?

Yes, you can copy paste the automation from my weather.yaml

Yup, already corrected the 16, was a typo. Supposed to be 1. I just copy/pasted the code from arsaboo to be safe.

Ok, I did that and just to make sure I deleted all the indents and used double spaces to make sure it wasnā€™t pasting with tabs. This is what happened after restarting with the automation:

https://hastebin.com/penacajodu.sql

And this is is the frontend now:

Remove the automation from weather.yaml and place it in your automations.yaml file. I am running out of ideas hereā€¦it has to be something minor.

Ok, something weird is happening now.

I pasted the code but was getting errors, so I removed the automation:
and left like this:

https://pastebin.com/yhSEX6u1

Sorry, for some reason hastebin wonā€™t let me save the code like that.

Anyway, I checked the config and Hassio said that it was valid. I restarted and now I got this on the frontend:

I clicked on the icon under Automation on the frontend and then clicked trigger, which made the weekday names appear. But this is a manual action, is there a way to make it automated as intended? And to hide that from the frontend. Also, the icons on the top shouldnā€™t be there anymore, right?

Okā€¦that is not bad. Just see if the automation is showing up in your entities and that it runs when a sensor is updated

1 Like