HADashboard weather with WUnderground

I can see in my code why it’s not updating, hopefully wil have it fixed and uploaded to github in the next couple of days.

Awesome, I look forward to the update. Cheers

@akkaria, I’ve made the updates, best to probably re-install all the files again from github. Updated instructions below (couldn’t edit the original post any longer). Let me know if you run into any issues.

In order to test things in appdaemon the files need to be added.

  1. create “custom_widgets” directory on the same level as the appdaemon.yaml file.
  2. create “basewunderground” directory in the “custom_widgets” directory.
  3. copy basewunderground.css, basewunderground.js, basewunderground.js files (from the github linked below) into the “basewunderground” directory.
  4. copy the wunderground.yaml file (from github, up one level from the css, js, html) to the “custom_widgets” directory (not inside the basewunderground directory, but a level above it).
  5. add the block outlined below to your skin variables.yaml file
  6. ensure your HA configuration.yaml settings for the wunderground component include the monitored conditions listed below.

Github Repository:

Content for your skin variables.yaml file (may have have be modified based on your skin):

wunderground_main_style: "color: $orange"
wunderground_unit_style: "color: $orange"
wunderground_sub_style: "color: $blue"
wunderground_widget_style: $background_style

HA configuration.yaml wunderground

temp_f
precip_1d
precip_2d
weather
weather_2d
temp_high_1d_f
temp_low_1d_f
temp_high_2d_f
temp_low_2d_f

Dash file definition:

weather:
  widget_type: wunderground
  widget_style: $black_background  //may depend on your skin
2 Likes

lordsiris,

I’ve been following this too and wanted to thank you for your work.
wanted to add a few other conditions so I’ve been working through the JS in your widget.

From what I can tell, most of what you did was refactor the

  var monitored_entities =  ...

Is that correct?

I added relative humidity to the primary (I’m a runner so I care about humidity more than a clean display).
In the JS I added the following:

{
"entity": "sensor.pws_relative_humidity",
"initial": self.OnUpdate,
"update": self.OnUpdate
},

and in the basewunderground.html I added:


I’m not sure how to post HTML without it interpreting it.

That gave me this:

Hi @lordsiris unfortunately the temp still doesn’t seem to be updating. I replaced all files as you mentioned but still no luck.

where does the variables.yaml file go?

you need to edit the variables.yaml from the skin you use.
if you dont use a skin, you use the default skin, so then you need to edit the variables.yaml from the default skin.
the default skin can be found in a subdirectory where you installed appdaemon (not the configuration dir)
most likely in a subdir from where python is installed

and ion HASSIO where is this?

somewhere on your SD card.
so you can use a search command to find it.
in general is it a smart idea to explore where things are installed on a device, so you have an idea what you are doing when you install something.

thank you for the information

what you expect?
that i come to your home to search on your SD card, where you have installed it?
i could tell you where mine is, but yours is for 100% sure on a different location :wink:

1 Like

from you nothing.

Mine is a question on an open forum, I await usable answers, since mine is a standard HASSIO installation.

I looked on the HASSIO card and nowhere there is variables.yaml or appadaemon word (just appdaemon in /config/appdaemon)

i gave you an answer and you react to it.
there is absolutely nothing wrong with searching yourself BEFORE asking.
when you have searched yourself and cant find it you could ask:

i searched for … that and that way, but i cant find it, can anyone tell me where it is and why i cant find it?
its better to learn to search yourself then let others do it for you and tell you where it is.

you probably looked on the wrong place. you need to look in the docker from appdaemon.
there must be an appdaemon folder, or else you wouldnt be able to run appdaemon :wink:
i also pointed you to the python folder.
if you find python, you can look for site-packages. (and thats the folder where you can find appdaemon, or in another environment homeassistant, or any other thing you installed in python.)

and if you search as a user that has no reading rights in that dir, you wont find it either.

1 Like

For anyone looking for variable yaml who has upgraded to python 3.6, I found mine here.

/usr/local/lib/python3.6/site-packages/appdaemon/assets/css/default

ReneTode - thanks for the good advice about working to understand where the packages are installed.

Question: Should or can Appdaemon run in a virtualenv?

I messed up some stuff today with conflicts over yarl versions between appdaemon and homeassistant. I think HA was using .18 and appdaemon wanted v 1. I can’t remember exactly which versions.

it is even adviced to use virtual environments (but i am not using them, because i experienced more problems with then without them :wink: )

so yeah, venv, docker or that kind off think can run AD and HA.

Thanks for you feedback. I think I’ll try running it venv and see what happens. It definitely does not play well with HA’s venv.

i got HA 0.61 and AD 3.0b2 without venv and i got no trouble, so it could be another problem that you experience.

Not in HASSIO, under that address is not.

I searched as root with winscp for variables.yaml and is nowhere

it is there.
only winscp cant find it as root.
you could look at something like /usr/local/lib/python
or find out where the docker packages are installed.

Have you tried clearing the browser/fully kiosk/app cache that is running the dashboard? I have been keeping a close eye on the temp updates and see it reflected on my various mounted tablets and browsers. With the code changes the initial state (first read of sensor data when dashboard is launched) and the updates its actually the same function so if it wasn’t updating I wouldn’t think it would get initial values to begin with either.