Closed tillstaff closed 3 years ago
I do love an issue that's already almost resolved ^^
I'm not sure that casting to a str
is the right thing to do though... Any idea how this state is used? If some or all elements of the dict
or the list
should be used as the actual state to be returned, str
would not cut it...
Any idea what a BLOB is?
Any idea what a BLOB is?
I haven't seen any example of a BLOB in this event context yet. Normally, a blob represents a file-like object of immutable, raw data. Via the mime type you are able to understand how to render the blob.
For now, I would just leave those out. I haven't seen any events using blobs yet. Perhaps they are used for camera's.
@vlebourl I don't have any idea about BLOB.
But for the two states linked, here are the references :
"name": "io:SensorsErrorState",
"type": 11,
"value": {
"outside": false,
"co2": false,
"outlet": {
"newAir": false,
"exhaustAir": false
},
"inlet": {
"newAir": false,
"exhaustAir": false
}
}
{
"name": "io:CO2HistoryState",
"type": 10,
"value": [54,53,53,54,57,56,57,57,56,56,55,55,54,58,55,51,55,56,56,55,56,56,56,56,57,57,59,56,52,50,49,48,47,46,46,46,46,45,45,45,44,45,45,44,45,45,50,53,59,63,58,57,56,56,57,57,58,58,53,48,45,51,53,53,54,54,56,61,62,59,59,59,59,59,58,55,53,52,51,49,48,47,47,46,46,45,45,46,46,46,46,51,54,53,55,54,52,51,50,49,49,51,52,54,54,52,51,51,49,48,49,51,54,54,55,56,56,57,55,55,55,56,57,53,50,47,46,45,44,44,44,44,43,43,44,44,44,44,45,50,51,53,51,57,22]
},
Could you try this branch: https://github.com/iMicknl/ha-tahoma/archive/fix/missing_datatype.zip before it's released?
@vlebourl I just tested this build and it's ok, thanks for your help.
Although, the debug logs show always "state: None -> None"? Is that normal?
2021-02-17 14:46:23 DEBUG (MainThread) [custom_components.tahoma.coordinator] EventName.DEVICE_STATE_CHANGED/None (device: io://xxxx-xxxx-xxxx/15021786#1, state: None -> None)
2021-02-17 14:47:23 DEBUG (MainThread) [custom_components.tahoma.coordinator] EventName.DEVICE_STATE_CHANGED/None (device: io://xxxx-xxxx-xxxx/15021786#1, state: None -> None)
yeah, that's normal I think. @iMicknl do you confirm?
Yes, this is normal behavior. Currently that only shows the execution state, thus that logging is quite limited still.
2021-02-12 17:52:39 DEBUG (MainThread) [custom_components.tahoma.coordinator] EventName.EXECUTION_STATE_CHANGED/xxxxxxxx-ac10-3e01-0169-e76212d8c5a3 (device: None, state: ExecutionState.INITIALIZED -> ExecutionState.NOT_TRANSMITTED)
Ok, it's good to know!
Describe the bug There are repeated errors in the logs when ha-Tahoma get states from some Cozytouch Devices (Atlantic Optimocosy in my case)
To Reproduce I made some investigations and the error is due to several Datatype not initialized in this object : https://github.com/iMicknl/ha-tahoma/blob/0612a5ba3e3cc7282923b2d7baf98e6d75897e6a/custom_components/tahoma/coordinator.py#L20-L27
The state values that make errors are :
Expected behavior Could you add the Datatypes missing?
The following code solved my problem :
According to the list of DataTypes available, maybe "DataType.BLOB" could be added too.