Because I have different types of switches and I’d like to handle their events differently.For example, some switches turn on lights and others turn on fans. You can assume that the handleSwitchEvent from my snippet deals with Lights differently.
The IDE is not throwing errors when they occur. Is it possible that is affecting this situation for you? I had an app where the devices were the same, but somewhere along the way how the platform executed the code in the two different functions changed. It was actuallly creating an error that was never thrown.
Thanks for your help on this but it seems to be a different issue. I’m trying to subscribe to events for 2 different groups of devices with the same capability but only one event handler is firing.
Never mind, it seems that breaking each event out into its own function, even though they are doing the same exact thing, fixed the issue. Seems like a bug but I’m good to go for now.
So if I understand what you’re saying, having two subscriptions to the same handler failed?
If so, then there was likely an error generated that wasn’t thrown such that you could see it. If this is the case, then this is really getting frustrating. And if so, then this IS the SAME problem. I hope they fix this soon!