Home assistant not processing all attributes of MQTT message

I’ll start by saying all of this was working a couple of days ago…and not even rolling back is fixing the problem.

I run HA on Proxmox in an LXC under Docker with MQTT in an LXC and zigbee2mqtt also now in a docker container within an LXC.

I used to run zigbee2Mqtt in an LXC standalone but the update script was broken and it didn’t upgrade to Debian Trixie well.

So jumping forward to this last weekend…I have installed a new LXC, including Docker, Debian Trixie and have Zigbee2MQTT running fin, talking to my SLZB-06.

I use MQTT explorer to debug all of the messages, but something is broken between MQTT and Home Assistant because not all of the data is being parsed.

I’ll give one specific example. I have an aqara buttin that in MQTT explorer is reporting the state information as follows…

{"action":"double","battery":100,"device_temperature":30,"linkquality":105,"power_outage_count":53,"voltage":3045}

In Home Assistant the button disappeared, but left behind all of the other attributes, battery, temperature etc.

I’ve tried deleting the device in zigbee2mqtt and HA, then rediscovering it and recreating it in HA…but the action attribute does not get picked up and I do not get the button behaviour to drive my scripts from.

I’m also seeing some errors from blueprints that used to work fine as well, but one thing at a time…

If the data is published to MQTT ok, as per my snapshot above, then I don’t see how it can be anything to do with the Zigbee side of the installation (unless you know different).

So why doesn’t HA identify the device as a button and process the action element?

I have 3 of these buttons all doing the same thing.

I have multiple other devices on MQTT that seem to work OK, but anything with an action seems to not register its behaviour.

I’m all ears if you have any clues…my wife isn’t going to be happy when she can’t turn on the TV!

I don’t understand why you would go through the trouble of setting up an LXC only to put a single docker container inside it. You may as well just use the Add-Ons / Integrations from within HA since it will handle updates from the UI.

My advice, is first move Home Assistant to Home Assistant OS in a VM and either use Add-Ons / Integrations to add MQTT and Zigbee2Mqtt or if you still want the separation go back to an LXC for each.

When looking to upgrade, if a script doesn’t work figure out why rather than just switching to a different installation method.

1 Like

Did you update your HA from an older version?

At some point, event entities were introduced as the preferred way to detect actions like presses. Check for an event entity associated with the device.

Just adding another of my switches, a TS004f has the same issue… everything is reported in HA except the action.

Here is what MQTT explorer sees

{
  "action": "2_single",
  "battery": 86,
  "linkquality": 72,
  "voltage": 2900
}

In the reals of “not helpful” that about takes the biscuit!

I have many LXC containers, and I run other things in the docker instance as well as zigbee2mqtt, my explanation was keeping things simple…

No, I didn’t update HA at all, still running on 2025.8.0

As far as I recall, zigbee2mqtt has always returned “action” representing the button behaviour, but as the entities pre existed recent updates it’s possible something has happened to that integration with MQTT to not interpret action any more.

I’ll dig about and see if there are any articles.

I’m not saying you can’t run things this way.

However, I did give you the suggestion to use a VM to run docker inside. Why? It is simply the fact that if you look at the history of Docker it initially used Linux Containers (lxc), however, now docker uses it’s own container runtime (libcontainer).

Anyway, a simple fact is you said you had an issue upgrading Zigbee2Mqtt since the update script was broken - you didn’t make any mention of trying to diagnose this. Instead you installed a new LXC with docker and the docker version of Zigbee2mqtt. So your zigbee2mqtt config has changed.

What version of Zigbee2mqtt were you running before the upgrade and what version after?

You sent me down the right track…thanks. Found this article that explains what was going on. No idea how it had been working for so long…but I should be able to sort it out now.

Using the new action events in Zigbee2MQTT 2.0

If you want an immediate fix you can enable Home Assistant Legacy Action Sensors on the Home Assistant Integration tab of the Zigbee2mqtt settings. Just note that these are deprecated so will be removed in the future.

Perhaps you upgraded Z2M with the setup changes you described, and the new version sends a different device configuration to HA that’s using the event entities.

Here, read this. Those are all the breaking changes for Z2M 2.0.
Bear in mind that there have been more Z2M releases since then, but they contained few (if any) breaking changes.