openhab/openhab-core

[UoM] Change default for Number:Dimensionless tio %

Closed this issue · 6 comments

See the related issue #3854 .

This request is to change the default unit for Dimensionless from ONE to %. By a very large amount, those who use Dimensionless are doing so for % (e.g. humidity). ppm and db are probably used more often than ONE, meaning that ONE is likely the least commonly used unit making it a really poor default.

This has been causing problems particularly for users of OH who upgrade from OH 3 to OH 4 as suddenly their percent Items are between 0 and 1 instead of 0 and 100 and their charts get messed up. This is somewhat mitigated for new Items by the fact that MainUI now allows the setting of the unit when the Item is created but it's catching many existing users.

It is a particularly confusing problem for many users because the binding may push a state description pattern so that the Item's state appears as a % in most places it's seen in the UI but the Item is actually carrying a state of unit ONE. "The overview tab shows 45%, why does my chart show .45?"

Your Environment

OH 4.1.1 running in Docker but that's not really relevant to this.

Please see my comment in the PR.

Perhaps also it is worth noting that strictly speaking the unit for humidity is properly not "%" but rather "% r.H." ..

Perhaps also it is worth noting that strictly speaking the unit for humidity is properly not "%" but rather "% r.H." ..

It is a ratio of densities expressed in %, so dimensionless: https://byjus.com/physics/unit-of-humidity/#:~:text=The%20absolute%20humidity%20unit%20is,per%20cubic%20metre%20of%20air. Writing r.H. behind it (relative Humidity) is clarification, but does not change the unit in my view.

Yes, "% r.H." extends "%" (to paraphrase in Java class syntax)

I think the webui PR which has been merged will have resolved this @rkoshak .. so probably this issue can be closed. ??

Agreed