Commit Graph

14 Commits (731f9ca7e0fabcd5cf8c37e08ce840d1a5222275)

Author SHA1 Message Date
Erik Montnemery 2caad1a474
Add support for converting to and from mmHg (#64844) 2022-01-24 22:57:56 +01:00
Tim Rightnour 93395f9b68
Add support for PRESSURE_CBAR (centibars) (#58762)
* Add support for PRESSURE_CBAR (centibars).  This is the standard UOM for tensiometers.

While the data could be converted into something like MBAR, and displayed
like that, the correct UOM for this type of sensor is CBAR.  Displaying
it as MBAR would be the same as displaying air pressure as feet of Hg, while
technically correct, it's hard to understand when reading.

Adding support for this UOM will fix errors in the UI(statistics) about the unit not
matching a unit of the device_class.

* Add tests for PRESSURE_CBAR
2021-11-10 09:44:05 +01:00
Glenn Waters e4f15c42e0
Add kPa as a pressure unit (#56885) 2021-10-01 08:08:04 -07:00
Daniel Hjelseth Høyer 49a69d5ba0
Add missing PRESSURE_BAR conversion (#54497)
* Add missing PRESSURE_BAR

* style

Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>

* valid units

Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>
2021-08-12 07:30:35 +02:00
Marc Mueller a56485a8c5
Revert new unit types (#53226) 2021-07-20 14:13:51 +02:00
Marc Mueller 71a8ae3016
Add new unit types for better type checking (#53124)
* Add new unit types
* Update helper functions
* Update components
* Update lcn climate
2021-07-18 14:43:47 +02:00
Erik Montnemery cca5964ac0
Normalize pressure statistics to Pa (#52298) 2021-06-29 23:30:13 +02:00
Philip Allgaier dde6305549
Cleanup unused loggers (components N-Z + tests) (#41982) 2020-10-16 21:24:08 -05:00
Ville Skyttä 221d5205e4
Upgrade mypy to 0.770, tighten config a bit (#32715)
* Upgrade mypy to 0.770, related cleanups

https://mypy-lang.blogspot.com/2020/03/mypy-0770-released.html

* Clean up config and make it a notch stricter, address findings
2020-03-12 11:52:20 +01:00
Bas Nijholt 67c56c860d Sort imports according to PEP8 for 'homeassistant' folder (#29789)
Components are already done
2019-12-09 16:42:10 +01:00
Franck Nijhof decf13b948 Use literal string interpolation in core (f-strings) (#26166) 2019-08-23 09:53:33 -07:00
Paulus Schoutsen 4de97abc3a Black 2019-07-31 12:25:30 -07:00
Ville Skyttä 56841da2d3 Upgrade mypy to 0.720, turn on unreachability warnings (#25157)
* Upgrade mypy to 0.720

* Turn on mypy unreachability warnings, address raised issues
2019-07-16 15:11:38 -07:00
MatthewFlamm ed93c3b2c1 Fix pressure in dark sky and openweathermap and add pressure utility (#21210) 2019-03-24 18:37:31 +01:00