mirror of
https://github.com/home-assistant/core.git
synced 2025-07-29 18:28:14 +02:00
Allow tuple subclasses to be json serialized (#74207)
This commit is contained in:
@ -33,7 +33,7 @@ def json_encoder_default(obj: Any) -> Any:
|
||||
|
||||
Hand other objects to the original method.
|
||||
"""
|
||||
if isinstance(obj, set):
|
||||
if isinstance(obj, (set, tuple)):
|
||||
return list(obj)
|
||||
if isinstance(obj, float):
|
||||
return float(obj)
|
||||
|
Reference in New Issue
Block a user