Hi, I’ve a long term openhab user and living with openhab3.1 on my raspberry satisfies my needs in smart home. as I have used it since openhab1.x I am still on a sitmaps navigation and on the shift to mpove to the pages. Here starts my struggle. My Items Dictionary seems completly empty.
This Otter_Absence is just one example - you see it’s value of 1.0 here:
You’ve shown that the Item exists in the Developer Sidebar.
You’s shown that the Item exists in the auto-completion dropdown.
So I think it’s pretty safe to say that the Item exists.
Even though you are an old hand with OH, definitely review the Getting Started Tutorial, in this case pay special attention to the Semantic Model. There is a lot of useful information there including
However, the model is not intended to represent all your Groups and Items…
Existing Items can be added to the model. Browse to the Item in the Items settings, click on Edit and choose an appropriate Semantic Class and Semantic Property. Then add the Point as a member of the appropriate Equipment or Location Group. If the Equipment Group doesn’t exist yet, create a Group and use the appropriate Equipment semantic tag first and add the Equipment to the appropriate Location Group.
If your Item doesn’t appear in the Model view then it has not been tagged with a semantic tag and therefore is not a part of your model.
Note that the above assumes the Items are managed. If they are defined in .items files you’ll need to add the tags and set the Group membership there and not through the UI.
Check your item’s stateDescription metadata (it looks like you have a map transform on the item perhaps?). The list of items on the items page shows the state of the item, but the widget at the top of the item details page, by default shows the displayState of the item, or the state after it has been modified by various other options. So right now your Otter_Absence item has a state of 1.0 but for some reason your stateDescription is returning a null value from that 1.0 state.
The state is even available in the widget editor; you can see in the tooltip in your screen shot that the state is one. So items.Otter_Absence.state should give you 1.0, but items.Otter_Absence.displayState will continue to give you - until you figure out what is wrong with the stateDescription metatdata.
thanks for suggestion!
true - I had a transform map but I wasted it meanwhile. With your suggestion I created a stateDescription (which was empty) and entered the old mapping values without any effect on the state in the Expression
Copy and paste where you’ve entered it. What field? What type of widget? I assume you are not in a rule. If you need to show context show the whole YAML code in the code tab.
In a Widget the expression starts with a = and then you have your expression. For example:
What options are you trying to show? It’s an expression tester. It tests the expressions. It shows what an expression returns. That’s what we want, right?
That’s exactly what we want to see with your “Otter_Absence” Item. Also note that the preview of a page while you are editing it does not update as the Items change state. Sometimes they don’t even show the current state when you first add them to the Page or as you make changes in then Custom Widget creator. You need to manually refresh to see updates and such. That’s why the Developer Sidebar is better for this sort of thing. As it is I can’t tell if it’s not working because it’s not working or because you haven’t refreshed.
so I looked in my firefox on mobile with the same result as the app… it presents the good result (as the Item state is 2 in the morning / believe me)
I restarted openhab, flushed browsers cache on my windows client and it still does not know about the state. now I do not feel dumb any more - but the error is somewhere out there. I have nothing in my openhab logs - where can I have a look to investigate further?
But that’s also the same result one gets if the Item exists but it’s state is NULL or UNDEF. So that’s not necessarily a good test for whether or not the Item exists. But it is informative.
If it’s showing in some browser/app but not other’s then the problem lies somewhere in the UI or the browser itself (perhaps an extension is blocking the SSE feed for example). At this point the best I can offer is to file an issue on the openhab-webui and gather logs from the browser.
On chrome, if I come back to a OH page I’ve left open for a while, I often find that I have lost the SSE feed. A page refresh is usually sufficient, though that doesn’t seem to be the case here.
What do you see if you click on the second button on the developer siderbar (the ~ image) and then press the Stream Events button?
What do you see in the sessions list if you click on the profile link in the bottom of the left panel?
I always asked myself what these Events are about and when do they appear bc I never get any. I clicked as you described and followed some links in the UI afterwards but not any event showed up. It is completly empty / what does this mean?
thats a good point! I used Firefox with a bunch of extensions and restrictions and MS Edge (chrome based) with default settings on . finally I installed chrome itself / all with the same result: missing state information of my items.
Maybe it’s some kind of firewall or so. to clarify: I use the same local adress from mobile phone (which works) and from windows client (which does not work). I’ve lost my SSL certificate so I will regenerate it and will try the remote address to check for differences