šŸ›” Watchman - keeps track of missing entities and actions in your config files

Make sure you went through all 3 steps mentioned in quick start.

Ah, sorry I missed this!

Hi scr, has the Lovelace check been removed from the latest version?

Iā€™m being asked to downgrade?

I have the same thing so ignored it for nowā€¦

1 Like

Me too. Looks like an extra dot got added in the version number last update.

Iā€™ve downloaded via HACS. Rebooted HA but when I try to add watchman as an integration it does not appear on the list. Not sure whatā€™s wrong.

Something strange seems to be happening with this integration. Iā€™m now being asked to massively downgrade to v0.2.5. And the release Iā€™m on seems to have disappeared (along with everything above 0.2.5). Anyone know what is going on here?

EDIT: Ok it looks like the tags still exist. I guess I wasnā€™t actively checking this repo, were there previously releases to go along with those tags or was it being managed entirely as tags? Still the issue of why Iā€™m being presented with a massive downgrade by HACS.

Itā€™s on the GitHub side, Iā€™ve fixed it for now without any guarantee it wonā€™t happen again.

2 Likes

So please help an old man out here :)ā€¦once I have this report, how do i actually go in and repair the error which the report has shown me?
Iā€™m sorry for the stupid question.
Are there any video tutorials on this?

It dependsā€¦
First, I doubt that anyone who has been tinkering with Home Assistant for a while doesnā€™t have missing entities.
If you arenā€™t experiencing problems, then this is just a matter of house cleaning.

Hereā€™s an example:

The missing service is from an automation that I was writing a long time ago. I meant to say ā€œswitch_turn_onā€ but forgot the ā€œonā€. If you use the UI to make automations, it will be difficult to make this mistake.

For the missing entities,
State: unavail - In my case, either the device is offline or itā€™s an old entry in a YAML file. ā€œwemos_blinkr_ledā€ is simply offline.

State: missing- ā€œsensor.freezerā€ was changed in the device yaml file to ā€œsensor.freezer_temperature_cā€, I need to change the entry in configuration.yaml (the Location column shows where sensor.freezer was specified, but not found.

history

State: unknown- This one took some research. The entity is good and I can turn the dining room light on and off from HA, so why is it ā€œunknownā€ in the report? In my case, this switch has recently decided to not send a status unless I turn it on or off:

dimning

I toggled the light and ran another Watchman report, and the ā€œunknownā€ disappeared. The problem is in my switch, not my automation.

Hope this helps.
As was said above, Watchman is only a snapshot of things to investigate or clean up. Most of us using Watchman for the first time were surprised at the remnants from older experiments or tinkering or deleted devices that have no effect on Home Assistant.

2 Likes

Thanks @stevemann for the great and detailed explanation!

Thereā€™s a short review on youtube: https://www.youtube.com/watch?v=XKD5vBZLKgE&t=3s

1 Like

Right!!..this makes total sense. Thanks for the explanationā€¦and patience :slight_smile:

Thank you very much

Nice add-on!

Question: Can I control how often Watchman checks files?

Right now it runs quite often but I only need it to run once a day.

The plugin is not working anymore in 2022.6.6

There are always zero errors, even though I have missing devices. It worked before the update and I didnā€™t change anything else.

Anyone else having this issue?

I updated to 0.6.0 and to 2022.6.6 at the same time. Not sure what is to blame.

No problems here.

From the watchman perspective this is a two-stage process:

  1. Re-parse configuration files when theyā€™re changed. This is a resource-intensive operation and it should not happen very often as it only triggers at HA reboot or when you reload a part of you configuration files via Developer tools->YAML-> YAML configuration reloading
  2. Update watchman sensors when any entity from previously parsed config (step 1) changes its state either to or from: ā€œmissingā€, ā€œunavailableā€, ā€œunknownā€. This can happen quite often if an entity from your configuration file changes its state, e.g. from unknown to 25 and back every minute or less.

The next version of Watchman will get the ability to disable sensors for those users who donā€™t need them. For the moment, a workaround is to identify the entity which triggers watchman sensors update and add it to the ignore list.
Hope this helps.

3 Likes

Does watchman.report work? The easiest way to test it is to add a yaml file to your /config folder with something like sensor.fake_sensor and run the report with ā€œparse_config=trueā€. This sensor should then appear in the report.

1 Like

Yes, it reports.

The problem was that the path was set to /config. Changed it to the full path and now it works again. But I think this behavior was different before.