Community Hass.io Add-on: AppDaemon 3

I’m not sure whether this is due to the latest update, or a change in the repo, but I’m using the python3-dev system package, which no longer seems to work due to version constraints elsewhere.

Config:

{
  "log_level": "info",
  "system_packages": [
    "linux-headers",
    "build-base",
    "python3-dev"
  ],
  "python_packages": [
    "bs4",
    "pychromecast"
  ]
}

This worked before, but now it results in this version constraint error:

ERROR: unsatisfiable constraints:
  python3-3.6.4-r1:
    breaks:
            python3-dev-3.6.6-r0[python3=3.6.6-r0]
    satisfies: world[python3=3.6.4-r1]
FATAL: Failed installing package python3-dev

@DarkFox

Python is installed in the container as well, but seems like a new version has been released between the last release of the add-on and now.

The version of python-dev you install now, does not match the Python installed in the container. Try adding the python3 package tot the system_packages. That will trigger the install of the matching Python version.

1 Like

That did the trick, thanks! :slight_smile:

1 Like

After update from 0.66.2 to HA 0.77.2 all sensors, switches etc. disappeared from all HADashboards.
I run Hassio on HassOS 2.2

AppDaemon log:

[cont-init.d] 00-banner.sh: exited 0.
[cont-init.d] 01-log-level.sh: executing... 
Log level is set to INFO
[cont-init.d] 01-log-level.sh: exited 0.
[cont-init.d] 02-updates.sh: executing... 
INFO: You are running the latest version of this add-on
[cont-init.d] 02-updates.sh: exited 0.
[cont-init.d] 20-init-configuration.sh: executing... 
[cont-init.d] 20-init-configuration.sh: exited 0.
[cont-init.d] 21-compiled-dir.sh: executing... 
[cont-init.d] 21-compiled-dir.sh: exited 0.
[cont-init.d] 30-auto-password.sh: executing... 
[cont-init.d] 30-auto-password.sh: exited 0.
[cont-init.d] 31-ha-url.sh: executing... 
[cont-init.d] 31-ha-url.sh: exited 0.
[cont-init.d] 50-compiled-symlink.sh: executing... 
[cont-init.d] 50-compiled-symlink.sh: exited 0.
[cont-init.d] 80-system-packages.sh: executing... 
[cont-init.d] 80-system-packages.sh: exited 0.
[cont-init.d] 81-python-packages.sh: executing... 
[cont-init.d] 81-python-packages.sh: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
2018-09-02 18:09:41.626196 INFO AppDaemon Version 3.0.1 starting
2018-09-02 18:09:41.627333 INFO Configuration read from: /config/appdaemon/appdaemon.yaml
2018-09-02 18:09:41.633815 INFO AppDaemon: Starting Apps
2018-09-02 18:09:41.652106 INFO AppDaemon: Loading Plugin HASS using class HassPlugin from module hassplugin
2018-09-02 18:09:41.756655 INFO AppDaemon: HASS: HASS Plugin Initializing
2018-09-02 18:09:41.759153 INFO AppDaemon: HASS: HASS Plugin initialization complete
2018-09-02 18:09:41.760999 INFO Starting Dashboards
2018-09-02 18:09:41.806596 INFO API is disabled
2018-09-02 18:09:41.855102 INFO AppDaemon: HASS: Connected to Home Assistant 0.77.2
2018-09-02 18:09:42.567794 WARNING AppDaemon: HASS: Disconnected from Home Assistant, retrying in 5 seconds
2018-09-02 18:09:47.600306 INFO AppDaemon: HASS: Connected to Home Assistant 0.77.2
2018-09-02 18:10:58.566735 WARNING AppDaemon: HASS: Disconnected from Home Assistant, retrying in 5 seconds
2018-09-02 18:11:03.597973 INFO AppDaemon: HASS: Connected to Home Assistant 0.77.2
2018-09-02 18:11:04.290430 WARNING AppDaemon: HASS: Disconnected from Home Assistant, retrying in 5 seconds
2018-09-02 18:11:09.325027 INFO AppDaemon: HASS: Connected to Home Assistant 0.77.2

Should be anything changed in settings?

did you use a password before? because now its needed to set an api password.

Appdaemon is 1 of the programs that needs the legacy password.

Yes, I use password, stored in secrets.yaml.
If I open HADashboard, it asks password after entering it dashboard opens, but instead of every single item is info “cannot find …”
The only items properly displayed and working are clock, iframes, navigate widgets and reload.

this is appdaemon.yaml

secrets: /config/secrets.yaml
log:
  logfile: STDOUT
  errorfile: STDERR
appdaemon:
  disable_apps: 1
  threads: 10
  app_dir: /config/appdaemon/apps
  plugins:
    HASS:
      type: hass
      ha_url: http://hassio/homeassistant
      ha_key: b7a78b1e4e35441c929dd5...................
hadashboard:
  dash_url: http://192.168.1.xxx:5050
  dash_dir: /config/appdaemon/dashboards
  dash_password: !secret dash_password

i didnt mean password in dashboard but in Homeassistant.
do you have

http:
  api_password: !secret http_password

in your home assistant configuration and is that the same as your ha_key in the appdaemon.yaml?

Ups, it might be the reason in my case ha_key is not the same as api_password. Going o test it.

1 Like

Strange, but after update to 77.3 the issue disappeared.
I left ha_key as it was and api_password as well.
Thank you anyhow … :+1:

For the record: That is correct. Hassio uses API keys, not the API password.

Thanks for correction…

After AppDaemon reboot is !secret dash_password in appdaemon.yaml rewritten to dash_password.
If I write down password directly to appdaemon.yaml it remains there untouched…but unsecure?

:tada: Release v1.5.0

Full Changelog

Changed

  • Adds Hassio API security role
  • Upgrades base image to v2.3.0
  • Upgrades Python to 3.6.6-r0

Questions? Join our Discord server! https://discord.me/hassioaddons
Enjoying my add-ons? Consider supporting my work: https://patreon.com/frenck

1 Like

:tada: Release v1.6.0

Full Changelog

Changed

  • Updates AppDaemon to 3.0.2 (#29) (@acockburn)
  • Upgrades gcc to 6.4.0-r9
  • Switches use of token instead of ha_key
  • Adds logic to automatically flush compiled cache on version upgrade
  • Improves token update message on startup

Questions? Join our Discord server! https://discord.me/hassioaddons
Enjoying my add-ons? Consider supporting my work: https://patreon.com/frenck

Excellent!

Can you tell if that release includes SockJS to support oldish ipads (ios 5.1.1)?

AppDaemon is running in the UTC timezone. I can’t figure out how to make it use my local timezone.

Hass.io shows the sunrise and sunset times correctly, so it seems to be honoring my settings.

Here is my appdaemon.yaml file: https://hastebin.com/vapehimubo.js I changed a few numbers for obvious reasons.

I have also tried adding time_zone and timezone to the config.json shown on the page (where you put the python modules you might need). This does not seem to be saving – it keeps getting erased when I add the extra parameter.

I could probably change the timezone of the Pi from a ssh instance but I understand that the machine is meant to stay in the UTC timezone. Is there anything else I can try?

Thanks!

there are a few places where you can set time.
device (Pi)
operating system (hassio)
home assistant
appdaemon.

appdaemon normally takes its time from homeassistant.
and allthough homeassistant shows local time in the frontend, it still uses UTC in the background if the device settings are wrong.

i dont know why the PI should stay in UTC, but thats the first place i would change it.

For hassio, the time for addons is set by the time zone defined in Home Assistant…

yeah i forgot to say that you dont need latitude, longtitude, timezone and elevation in the appdaemon.yaml unless there you dont get the time from HA resulting in errors. (so better delete it)

I’m still getting UTC as the time zone within AppDaemon. I have a fix for the OccuSim program that takes a local timezone argument from the yaml settings file. Internally, the program sees everything in UTC.

I have tried setting the time_zone variable in the appdaemon.yaml file as shown above but AppDaemon does not honor it. I would love to get rid of my timezone fix but for now it does the job neatly.

When I’m sure my version of OccuSim is working to my satisfaction, I’ll post it on the OccuSim thread for review. I have a few other changes so I want to do it all at once.

Edit: This could very well be a misconfiguation on my part. As I said above, the Hass.io frontend is showing the correct time for sunrise/sunset/etc. so I think things are correct. I have it running from the rpi image and I think it’s pretty vanilla at this point.