My practical experience is delete the capability and create new adding a number behind de name of capability and leave the attributes and commands with the same name and create a new presentation of the capability. In this way in the Driver code you just have to change the profile capability name and declaration of the Custom Capability, the rest is valid
Another way that usually works immediately is to create a vid with the new presentation of capability. This makes the presentation update.
If you have to modify it again, you have to create another different vid, for that you can add capabilities that the device does not have, It will not affect the operation of the vid, it will only show the capabilities that the device have.
I do not understand how they do not fix this for a capability update is a truth update.
@nayelyz say to me that in 24 hours they are automatically updated, but this has never worked for me and I have tried it several times.
But in this case, I think, @ygerlovin is experiencing the error in the “capability definition”. It happened to me a while ago, that I changed the capability’s attribute name and I got an error in the driver that there was no attribute with that name (which I confirmed was correct).
What I did was:
Delete the device and driver completely
Reboot the Hub
After the reboot, create the driver package again with a different name
Please, let me know your results, that should force a complete refresh, but I’ll try to replicate the issue again so I can report it to the team. I thought I did something wrong that caused this error, but now that you’ve also seen it, it is worth investigating.
I just experienced this as well. I had an object type capability with a list of enums. I wanted to add an additional enum for the next release. I regenerated the custom vid and got it to show up in the UI, but I am still unable to use this new value. I get this error when I try to use it to set the state.
Office thread encountered error: [string "st/dispatcher.lua"]:233: Error encountered while processing event for <Device: XXX (My Device)>:
arg1: table: 0x2bba790
[string "st/dispatcher.lua"]:233: Error encountered while processing event for <Device: XXX (My Device)>:
arg1: table: 0x2bba790
[string "st/capabilities/init.lua"]:226: Value myNewValue is invalid for myCapability.myState
@nayelyz Since the UI updated, do you think the capability itself will update as well?
I’ve seen it can take a while, for example, once I made a change in the custom capability definition, and I was able to use the new version the next day; but, I also had my Hub turned off for several hours so I don’t know exactly what triggered the update.
I already reported this issue to the team, I’ll ask them for an update, so, please help me monitor the behavior of your driver.
In this case, are you trying to update a driver in production (used by others)?