Prepare for upcoming mypy update (#70800)

This commit is contained in:
Marc Mueller 2022-04-26 16:41:52 +02:00 committed by GitHub
parent 7d2363ad22
commit 97af164858
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 8 additions and 7 deletions

View file

@ -236,7 +236,7 @@ class StatisticsSensor(SensorEntity):
samples_max_age: timedelta | None,
precision: int,
quantile_intervals: int,
quantile_method: str,
quantile_method: Literal["exclusive", "inclusive"],
) -> None:
"""Initialize the Statistics sensor."""
self._attr_icon: str = ICON
@ -252,7 +252,7 @@ class StatisticsSensor(SensorEntity):
self._samples_max_age: timedelta | None = samples_max_age
self._precision: int = precision
self._quantile_intervals: int = quantile_intervals
self._quantile_method: str = quantile_method
self._quantile_method: Literal["exclusive", "inclusive"] = quantile_method
self._value: StateType | datetime = None
self._unit_of_measurement: str | None = None
self._available: bool = False