mirror of
https://github.com/home-assistant/core.git
synced 2025-07-13 08:17:08 +00:00
Don't convert Climacell forecast temperatures to celsius because platform does it automatically (#47406)
This commit is contained in:
parent
541e166317
commit
972baa2ce4
@ -22,7 +22,6 @@ from homeassistant.const import (
|
|||||||
LENGTH_MILES,
|
LENGTH_MILES,
|
||||||
PRESSURE_HPA,
|
PRESSURE_HPA,
|
||||||
PRESSURE_INHG,
|
PRESSURE_INHG,
|
||||||
TEMP_CELSIUS,
|
|
||||||
TEMP_FAHRENHEIT,
|
TEMP_FAHRENHEIT,
|
||||||
)
|
)
|
||||||
from homeassistant.helpers.entity import Entity
|
from homeassistant.helpers.entity import Entity
|
||||||
@ -31,7 +30,6 @@ from homeassistant.helpers.typing import HomeAssistantType
|
|||||||
from homeassistant.util import dt as dt_util
|
from homeassistant.util import dt as dt_util
|
||||||
from homeassistant.util.distance import convert as distance_convert
|
from homeassistant.util.distance import convert as distance_convert
|
||||||
from homeassistant.util.pressure import convert as pressure_convert
|
from homeassistant.util.pressure import convert as pressure_convert
|
||||||
from homeassistant.util.temperature import convert as temp_convert
|
|
||||||
|
|
||||||
from . import ClimaCellDataUpdateCoordinator, ClimaCellEntity
|
from . import ClimaCellDataUpdateCoordinator, ClimaCellEntity
|
||||||
from .const import (
|
from .const import (
|
||||||
@ -102,10 +100,6 @@ def _forecast_dict(
|
|||||||
precipitation = (
|
precipitation = (
|
||||||
distance_convert(precipitation / 12, LENGTH_FEET, LENGTH_METERS) * 1000
|
distance_convert(precipitation / 12, LENGTH_FEET, LENGTH_METERS) * 1000
|
||||||
)
|
)
|
||||||
if temp:
|
|
||||||
temp = temp_convert(temp, TEMP_FAHRENHEIT, TEMP_CELSIUS)
|
|
||||||
if temp_low:
|
|
||||||
temp_low = temp_convert(temp_low, TEMP_FAHRENHEIT, TEMP_CELSIUS)
|
|
||||||
if wind_speed:
|
if wind_speed:
|
||||||
wind_speed = distance_convert(wind_speed, LENGTH_MILES, LENGTH_KILOMETERS)
|
wind_speed = distance_convert(wind_speed, LENGTH_MILES, LENGTH_KILOMETERS)
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user