Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

lib/extension/groups.ts bug: group with a Hue Dymera (endpoints 11/12) never goes OFF from member state changes

Open Beginner friendly
#33,373 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

@cristianchiriac is already working on this.

Since Oct 16, 2026.

  • #33410 by @cristianchiriac — open

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
65/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
typescript
Domain
embedded-iot

Research direction

Start in areAllMembersOffOrClosed() in lib/extension/groups.ts, where the state key is picked by indexing endpointNames with member.ID. Compare it with onStateChange() in the same file, which uses device.endpointName(member). The issue says the plain state key is stale for the Dymera, so check whether the group should read the endpoint-suffixed key. Done when a group with both Dymera endpoints goes OFF after all members report OFF, and the existing group tests still pass.

Written by the indexing model from the issue text.

Description

problem
What happened?

I have groups that include both endpoints of a Hue Dymera (top = 11, bottom = 12). Groups stay ON when all member devices are turned off. Groups only show state=off if the group itself is set with a state=off command. Groups with the same other members but without the Dymera device work fine.

I think the problem is this in areAllMembersOffOrClosed() in lib/extension/groups.ts:
endpointNames.length >= member.ID ... ? state_${endpointNames[member.ID - 1]} : "state"

member.ID is the endpoint ID (11/12), not an index, so for the Dymera it falls back to the plain state key. That key never changes (the reports update state_top & state_bottom), and on my device it stays ON as long as it's powered, so the group never counts as all off.

What did you expect to happen?

Group state changes to OFF once all members are off (off_state: all_members_off).

How to reproduce it (minimal and precise)
  1. Group with both Dymera endpoints and one other bulb, all on.

  2. Turn each member off directly (<bulb>/set, <dymera device name>/top/set, <dymera device name>/bottom/set with {"state":"OFF"}), not through the group.

  3. All members report OFF, the group stays ON.

Zigbee2MQTT version

2.14.1

Adapter firmware version

EmberZNet 8.0.2

Adapter

SMLIGHT SLZB-06MG24, Ember over TCP

Setup

Proxmox LXC. Group options are defaults.

Device database.db entry

{"id":144,"type":"Router","ieeeAddr":"0x001788010de27065","nwkAddr":33601,"manufId":4107,"manufName":"Signify Netherlands B.V.","powerSource":"Mains (single phase)","modelId":"LCW005","epList":[11,12,242],"endpoints":{"11":{"profId":260,"epId":11,"devId":269,"inClusterList":[0,3,4,5,6,8,4096,64515,768,64513,64516],"outClusterList":[25],"clusters":{"genBasic":{"attributes":{"hwVersion":0,"zclVersion":8,"dateCode":"20260522","swBuildId":"1.163.1","modelId":"LCW005","manufacturerName":"Signify Netherlands B.V.","powerSource":1,"appVersion":2,"stackVersion":1}},"lightingColorCtrl":{"attributes":{"colorCapabilities":31,"colorTempPhysicalMin":153,"colorTempPhysicalMax":500}},"genOnOff":{"attributes":{"onOff":1}},"genLevelCtrl":{"attributes":{"currentLevel":55}},"manuSpecificPhilips2":{"attributes":{"state":{"type":"Buffer","data":[11,0,1,140,60,138,176,103]}}}},"binds":[{"cluster":8,"type":"endpoint","deviceIeeeAddress":"0x90395efffeb245b5","endpointID":1},{"cluster":6,"type":"endpoint","deviceIeeeAddress":"0x90395efffeb245b5","endpointID":1}],"configuredReportings":[{"cluster":8,"attrId":0,"minRepIntval":5,"maxRepIntval":3600,"repChange":1},{"cluster":6,"attrId":0,"minRepIntval":0,"maxRepIntval":3600,"repChange":0}],"meta":{"onLevelSupported":false}},"12":{"profId":260,"epId":12,"devId":269,"inClusterList":[0,3,4,5,6,8,64515,768,64513],"outClusterList":[],"clusters":{"genBasic":{"attributes":{"hwVersion":0,"modelId":"LCW005","manufacturerName":"Signify Netherlands B.V.","powerSource":1,"zclVersion":8,"appVersion":2,"stackVersion":1,"dateCode":"20260522","swBuildId":"1.163.1"}},"lightingColorCtrl":{"attributes":{"colorCapabilities":31,"colorTempPhysicalMin":153,"colorTempPhysicalMax":500}},"genLevelCtrl":{"attributes":{"currentLevel":52}},"genOnOff":{"attributes":{"onOff":1}},"manuSpecificPhilips2":{"attributes":{"state":{"type":"Buffer","data":[7,0,1,209,77,1]}}}},"binds":[{"cluster":8,"type":"endpoint","deviceIeeeAddress":"0x90395efffeb245b5","endpointID":1},{"cluster":6,"type":"endpoint","deviceIeeeAddress":"0x90395efffeb245b5","endpointID":1}],"configuredReportings":[{"cluster":8,"attrId":0,"minRepIntval":5,"maxRepIntval":3600,"repChange":1},{"cluster":6,"attrId":0,"minRepIntval":0,"maxRepIntval":3600,"repChange":0}],"meta":{"onLevelSupported":false}},"242":{"profId":41440,"epId":242,"devId":97,"inClusterList":[],"outClusterList":[33],"clusters":{},"binds":[],"configuredReportings":[],"meta":{}}},"appVersion":2,"stackVersion":1,"hwVersion":0,"dateCode":"20260522","swBuildId":"1.163.1","zclVersion":8,"interviewCompleted":true,"interviewState":"SUCCESSFUL","meta":{"configured":"0.0.0"},"lastSeen":1791684984655}

Debug log

z2m1_debug_2026-10-13_1144.log

Notes

The stale plain keys ("state":"ON","brightness":140,"color_temp":333 next to the _top / _bottom ones) match the cached manuSpecificPhilips2 state on endpoints 11 and 12 above, so it looks like the Hue native-state parsing writes them without the endpoint suffix. {"state":"ON"} to top/set and bottom/set brought both back at brightness 140 instead of their previous levels.

Possible fix: use device.endpointName(member) here like onStateChange() does.

Probably the same bug: #28868 (closed as stale. there the plain key was OFF, so the group went off too early). The indexing came in with #25059. The open PR #32688 uses the same endpointNames[member.ID - 1] pattern.

Dominant language
TypeScript
Stars
15.7k
Forks
2k
Avg merge
16h 42m
Merged PRs (30d)
34

Getting set up

Open in Codespaces

Starts the project's dev container in your browser, under your own GitHub account.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from Koenkk/zigbee2mqtt

All issues in Koenkk/zigbee2mqtt

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.