Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[UoM] Change default for Number:Dimensionless tio % #4077

Closed
rkoshak opened this issue Feb 2, 2024 · 6 comments
Closed

[UoM] Change default for Number:Dimensionless tio % #4077

rkoshak opened this issue Feb 2, 2024 · 6 comments
Labels
enhancement An enhancement or new feature of the Core

Comments

@rkoshak
Copy link

rkoshak commented Feb 2, 2024

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.

@J-N-K
Copy link
Member

J-N-K commented Feb 2, 2024

Please see my comment in the PR.

@andrewfg
Copy link
Contributor

andrewfg commented Feb 3, 2024

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

@mherwege
Copy link
Contributor

mherwege commented Feb 3, 2024

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.

@andrewfg
Copy link
Contributor

andrewfg commented Feb 3, 2024

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

@andrewfg
Copy link
Contributor

andrewfg commented Mar 3, 2024

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

@rkoshak
Copy link
Author

rkoshak commented Mar 3, 2024

Agreed

@rkoshak rkoshak closed this as completed Mar 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement An enhancement or new feature of the Core
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants