You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
If _state_helper is called on a class which extends EntityInfo which contains a datetime member, the following error results:
TypeError: Object of type datetime is not JSON serializable
Describe the solution you'd like
changing the json.dumps at approximately line 771 in init.py in the write_config method from
config_message = json.dumps(self.generate_config())
to
config_message = json.dumps(self.generate_config(), default=str)
fixes the problem
Describe alternatives you've considered
Changing the EntityInfo to remove or change the datetime, this is not ideal as conversion is required for comparison
Additional context
Add any other context or screenshots about the feature request here.
The text was updated successfully, but these errors were encountered:
Is your feature request related to a problem? Please describe.
If _state_helper is called on a class which extends EntityInfo which contains a datetime member, the following error results:
TypeError: Object of type datetime is not JSON serializable
Describe the solution you'd like
changing the json.dumps at approximately line 771 in init.py in the write_config method from
config_message = json.dumps(self.generate_config())
to
config_message = json.dumps(self.generate_config(), default=str)
fixes the problem
Describe alternatives you've considered
Changing the EntityInfo to remove or change the datetime, this is not ideal as conversion is required for comparison
Additional context
Add any other context or screenshots about the feature request here.
The text was updated successfully, but these errors were encountered: