openHAB 4.0 Release discussion

Ok, big incompatible changes on units. Read all the links but they’re a bit unclear to me. What is clear, it’s important. Is there a readable instruction what to prepare for a user that only uses the UI. Or someone that can shed some more light?

What I understand/see:
The channels on the thing have a property “unit” when the advanced is checked. They are almost all empty.
The items have a state description metadata. Some of them are filled.
There is a conversion script that might do some things automatic.

The safest seems adding unit and state description on all of them. That’s a lot of work. Is it necessary?

Hi, I’m a little bit confused. On a lot of places there is Java 17 to install before start the upgrade, on the download page for the stable version of OH 4 for Linux / APK / stable 4.0.0 there was communicated Java 11. Would it be forget to change or is Java 11 necessary. For 4.0.1 Snap there is Java 17. Before I run into a problem and must reset all I will ask.

Thanks
Christian

You need Java 17, it seems the download page hasn’t been updated yet.

Many thanks !

I actually find the release notes on UoM changes to be pretty precise, please take your time to re-read them. If you still feel they’re unclear open a new thread please and put up specific questions of yours there. But please no “it’s unclear, explain it to me again” that won’t motivate anyone.

3 Likes

A post was split to a new topic: OH4 upgrade issue

after I updated to openhab 4, I have now no sitemap and not things, I have everything done file based, I can see all items, transformations and rules, the items also changing the values like temperature sensors, so it is working, but strange that I can’t see anymore the thing to it.
when I try to open the sitemap, it tells me I didn’t define a sitemap.
has someone the same?

I use openhab in docker

Apologies, changed my post to “unclear to me”. Of course, it depends on knowledge of the reader.

I know, that there are many changes to the UoM. I had prepared my openHAB (file based) configuration and correct some items in openHAB 3.4.4 before I upgraded. I also read the information about Humidity and added the “,unit=”%" to the Netatmo items. This worked. Also one Shelly H&T was changed later after the openHAB 4 migration (and before I wrote here).

Then I start to go to all properties and checked them and found as a result the rain gauge items with wrong units. After I changed them and it rained two hours later, nothing happened with the measured values.

There was nothing. I checked last night. I restarted last night openHAB 4 again and have now to wait. Today it was dry, no rain anywhere.

Hi Florian,

I can check and try on Friday or weekend, actually I am not at home and my configuration is file based. I will replay again later this week.

When I use the iOS openHAB-App (version 2.4.46), all properties are in English. The menu is called in German “Eigenschaften” and then I changes to English:

ColorTemperature, Current, Energy, Humidity, …

I can swear that the same menu in the app was with openHAB 3.4 translated to German. Also when I used the WebUI over Safari, everything is translated to German. It is only the app view, cache was clear for testing.

Sorry about that! It will now also instruct users to install Java 17 on Download openHAB | openHAB.

3 Likes

Well, there is a ton that happens between a device and seeing an Item updated. Nothing you describe points to the UoM having anything to do with the behavior you describe. It is much more likely that the binding isn’t connecting to the device or the Items are not linked correctly to the Channel.

There is nothing about UoM that would prevent an Item from updating silently. So if you see no errors complaining about incompatible units or something, the Item was never attempted to be updated. Your problem lies elsewhere.

Netatmo rain gauge is working fine for me in OH4.
As you can see, 8 mm of rain today.

And here are my item definition:

Number:Length PluieJour "Précipitations jour [%.0f mm]" <rain> (GNetatmoMeteoExt) [ "Measurement", "Rain" ] {channel="netatmo:rain:compte:station:pluviometre:rain#sum-24", unit="mm"}

Can you show also the state description?

Hello,

Meanwhile I fixed it. I have deleted the values and linked it new. Include the % in the unit.
It is shown now currect…

1 Like

After the update to 4.0 everything seems to work correctly again. However, I had to spend a whole day troubleshooting and solving one error message after the other. Fortunately, most errors are already discussed and solved here in the forum. But a simple update is something else.

1 Like

After upgrade from 3.4.4 to 4.0 when calling setTimer from JavaScript it returns undefined instead of a timer id.

To reproduce create testTimer.js with the following code:

console.info('before');
const id = setTimeout(() => {
  console.info('timer reached');
}, 1000);
console.info(`timer ${id} created`);

With release 3.4.4 I get:

2023-07-26 11:21:00.638 [INFO ] [ort.loader.AbstractScriptFileWatcher] - Loading script '/openhab/conf/automation/js/testTimer.js'
2023-07-26 11:21:13.275 [INFO ] [.automation.script.file.testTimer.js] - before
2023-07-26 11:21:13.281 [INFO ] [.automation.script.file.testTimer.js] - timer 1 created
2023-07-26 11:21:14.284 [INFO ] [.automation.script.file.testTimer.js] - timer reached

But in 4.0.0 with the same script I get:

2023-07-26 11:19:33.707 [INFO ] [ort.loader.AbstractScriptFileWatcher] - (Re-)Loading script '/openhab/conf/automation/js/testTimer.js'
2023-07-26 11:19:37.257 [INFO ] [.automation.script.file.testTimer.js] - before
2023-07-26 11:19:37.259 [INFO ] [.automation.script.file.testTimer.js] - timer undefined created
2023-07-26 11:19:38.259 [INFO ] [.automation.script.file.testTimer.js] - timer reached

Openhab is running as docker container on a raspberry.

Is this a known issue?

It wasn’t, but yet it is :wink:

I will provide a fix ASAP.

EDIT: Fix is already merged and will come with openHAB 4.0.1 soon.

3 Likes

Updated from OH3.4 via apt with reading all your (awesome) documentations and it worked flawlessly.
Using mostly file-based configs and rules and many add-ons and stuff.
Big thanks to all your great work! I am deeply impressed! Now discovering all new features. :slight_smile:
I like you! :heart_eyes:

5 Likes