File tree Expand file tree Collapse file tree 4 files changed +19
-4
lines changed
custom_components/weatherlink Expand file tree Collapse file tree 4 files changed +19
-4
lines changed Original file line number Diff line number Diff line change 3
3
from enum import StrEnum
4
4
5
5
DOMAIN = "weatherlink"
6
- VERSION = "2024.4 .0b0"
6
+ VERSION = "2024.10 .0b0"
7
7
8
8
MANUFACTURER = "Davis Instruments"
9
9
CONFIG_URL = "https://www.weatherlink.com/"
Original file line number Diff line number Diff line change 13
13
"issue_tracker" : " https://github.com/astrandb/weatherlink/issues" ,
14
14
"requirements" : [],
15
15
"ssdp" : [],
16
- "version" : " 2024.4 .0b0" ,
16
+ "version" : " 2024.10 .0b0" ,
17
17
"zeroconf" : []
18
18
}
Original file line number Diff line number Diff line change @@ -784,7 +784,22 @@ def generate_model(self):
784
784
def native_value (self ):
785
785
"""Return the state of the sensor."""
786
786
# _LOGGER.debug("Key: %s", self.entity_description.key)
787
- if self .entity_description .key not in ["WindDir" , "BarTrend" ]:
787
+ if self .entity_description .key not in ["WindDir" , "BarTrend" , "WindGust" ]:
788
+ return self .coordinator .data [self .tx_id ].get (self .entity_description .tag )
789
+
790
+ if self .entity_description .tag in [DataKey .WIND_GUST_MPH ]:
791
+ if (
792
+ self .coordinator .data [self .tx_id ].get (self .entity_description .tag )
793
+ is None
794
+ ):
795
+ return None
796
+ if (
797
+ float (
798
+ self .coordinator .data [self .tx_id ].get (self .entity_description .tag )
799
+ )
800
+ < 0
801
+ ):
802
+ return 0.0
788
803
return self .coordinator .data [self .tx_id ].get (self .entity_description .tag )
789
804
790
805
if self .entity_description .tag in [DataKey .WIND_DIR ]:
Original file line number Diff line number Diff line change 1
1
[bumpver]
2
- current_version = 2024.4 .0b0
2
+ current_version = 2024.10 .0b0
3
3
version_pattern = YYYY.MM.PATCH[PYTAGNUM]
4
4
commit_message = " Bump version from {old_version} to {new_version}"
5
5
commit = False
You can’t perform that action at this time.
0 commit comments