Multiple .items files: in some files items are not shown in sitemap

Hi community!
In the past days I stumbled upon an unexpected behavior in OH2.5 that I would like to understand better.
I try to modularize different sets of functions in my configuration as good as possible. Therefore usually I create multiple .items and .rules files for the individual functionalities.
For example I have “alarm.items”, “default.items”, “presence.items” etc. On the other hand I have a sitemap to show them all :wink:
Now I had the case that a group or item is not shown in sitemap when I put it into “alarm.items” but everything is just fine if I put it to “default.items” it seems.

All the .items files are in the same correct config directory.

This is what I get when I try to show the sitemap (that contains a group item “gAlarm”:

==> /var/log/openhab2/openhab.log <==

2021-02-25 19:36:40.478 [ERROR] [ui.internal.items.ItemUIRegistryImpl] - Cannot retrieve item for widget org.eclipse.smarthome.model.sitemap.sitemap.Group

2021-02-25 19:36:40.491 [ERROR] [ui.internal.items.ItemUIRegistryImpl] - Cannot retrieve item ‘gAlarm’ for widget org.eclipse.smarthome.model.sitemap.sitemap.Group

2021-02-25 19:36:40.496 [ERROR] [ui.internal.items.ItemUIRegistryImpl] - Cannot retrieve item ‘gAlarm’ for widget org.eclipse.smarthome.model.sitemap.sitemap.Group

2021-02-25 19:36:40.500 [ERROR] [ui.internal.items.ItemUIRegistryImpl] - Cannot retrieve item ‘gAlarm’ for widget org.eclipse.smarthome.model.sitemap.sitemap.Group

Also I mentioned that items from “alarm.items” are also missing from the rules perspective. For example I see this in my log:
2021-02-25 19:25:30.860 [ERROR] [ntime.internal.engine.RuleEngineImpl] - Rule ‘FridgeDoorOpen’: The name ‘FridgeOpen_Alarmdelay’ cannot be resolved to an item or type; line 69, column 55, length 21

Any idea what can be the reason? I suspect some file format or something although I cannot see any difference between the differnt files…

When you edit and save alarm.items does your log show anything interesting?

No nothing interesting was shown in this point of time. I now created a new file “alarms.items” and deleted the old “alarm.items” and now it works fine. Must have been some issue with the file itself. Although I could not see any differens in rights etc…
Nevermind. For me it is solved now. Thanks for trying to help :slight_smile:

P.S.: after re-naming “alarms.items” back to “alarm.items” still OK. So the name was not the issue

Yeah, this can happen. Did you create or edit your original alarm.items from a different device or using different software at any point?

I don’t suppose you happen to have an alarm.rules or alarm.things file as well?