Steps to reproduce:
- Create a copy of the XYZ plugin file called "XYZ Plugin Test".
- Edit the "XYZ Plugin Test" Info.plist file to make Indigo treat it as an entirely different plugin instance.
- Make sure there's no indiPref file associated with "XYZ Plugin Test" so that it's installed as a new plugin.
- Install the plugin and complete configuration as normal.
- Duplicate an existing device from the "real" XYZ Plugin.
- Open the device config and change the device type from "XYZ Plugin" to "XYZ Plugin Test". The device model goes to "no device type selected' and I get:
- Code: Select all
Error device "ABC" state key onOffState not defined (ignoring update request)
When I reselect the device model, everything works as expected. Device ABC does have the 'onOffState' defined in Devices.xml and in the existing device I copied from. When the new device "ABC Test" cycles, it runs without error. The KeyError above only happens at the point I switch the type. Of course, there are many other device states, but it only KeyErrors on 'onOffState'.
This is likely a low-order thing as a user would never run into it. I just find it curious.