I created some Items with names that started with a number such as “2ndBathTubMotion”. This has worked fine in the past, but under 3.3 M6 it has stopped working. I realize now that this isn’t allowed, but it seems it hasn’t been enforced in the past. Is this a new check?
The real question is how to resolve this. I think the easiest way might be to shut down OH and edit the JSON files directly to change ‘2nd’ to ‘Second’. Since I can no longer see the illegal items in the OH GUI, I can’t edit them there. Any other way to fix this? I suppose I could go back to an earlier OH version and fix the Item names there, then go forward again to OH 3.3 M6.
No, as Items cannot be renamed, just labels can be changed. Don‘t matter which openHAB version.
So the solution is to stop OH and edit the JSON directly? I can do that, just checking.
Yes, this has never been allowed but only now is it being enforced.
Because they won’t appear in MainUI that probably means they cannot be seen in the REST API either. You might be able to get at them from the karaf console but I’m not sure. So you are kind of stuck.
I see two options:
Downgrade OH to the previous milestone, delete and recreate the Items in MainUI (as hmerk indicates, you cannot rename an Item).
See OH 3 Tips and Tricks and scroll down to the “Editing the JSONDB as a Last Resort” section.
Note that 2 is relatively dangerous as one typo can corrupt the whole file and it’ll be hard to find the error. Also be aware that this too isn’t renaming. All the history, UI widgets, and everything else that references that Item will need to be changed too to use the new Item.