How to debug UI not updating errors

Quite frequently I see postings about problems with some element on the UI not updating. There is a whole lot that takes place between a device sending a message and the UI in the browser or phone updating.

This posting provides an approach for how to work through the whole path to identify where the error is taking place.

  1. Verify that the device is actually sending the message. If using MQTT use a third party subscriber to verify the message is actually being posted to the expected topic. If using some other communications mechanism look at logs, tcpdump, or whatever is appropriate.

  2. Verify that openHAB is receiving the message without error. Look in events.log for updates and/or state changes to the Item linked to the binding/channel. Look in openhab.log for error messages. Pay attention to the openHAB logs during OH startup for errors or successful connections from the binding initialization.

  3. Verify Rules get triggered when these Items get updated. Trigger the rule with a “received update” and log out the Item’s state. Verify the Rule is triggered and the Item is the correct state in the Rule by viewing openhab.log.

  4. Verify the UI is reflecting the correct state of the Item. Simplify the way the Item is presented on the sitemap is possible by eliminating overridden labels, icons, dynamic elements, etc.

Work through these steps in order.

If you don’t see the message at 1 the problem is with your device or with your computer’s ability to communicate with the device.

If you don’t see the message at 2. the problem is with the OH configuration or the Item configuration.

If you don’t see the message at 3. there might be an error with your Rules (possibly a syntax error).

If you don’t see the message at 4 the problem is in the UI. There might be a problem with the sitemap or a bug in the UI.

3 Likes