vicfergar / HassClient

A Home Assistant client using Web Sockect API
GNU General Public License v3.0
18 stars 10 forks source link

Exception using homeassistant beta #5

Closed shaonianzhentan closed 2 years ago

shaonianzhentan commented 2 years ago
Newtonsoft.Json.JsonSerializationException:“Error converting value "2021.12.0b3" to type 'System.Version'. Path 'ha_version', line 1, position 53.”

ArgumentException: Could not cast or convert from System.String to System.Version.

image

vicfergar commented 2 years ago

Hi @shaonianzhentan,

Good catch! Looks like System.Version does not supports letters. I think it would be better to map 'ha_version' into string or a custom type.

As a workaround, I recommend you to change it to string.

shaonianzhentan commented 2 years ago

Thank you for your suggestion. I returned ha to the official version

vicfergar commented 2 years ago

It should be fixed on v1.0.11