We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5d961d4 commit 7ddbd4aCopy full SHA for 7ddbd4a
src/ham/things.py
@@ -1,6 +1,6 @@
1
from abc import ABCMeta, abstractmethod
2
import json
3
-from typing import Union, TYPE_CHECKING, ClassVar, Any
+from typing import Union, TYPE_CHECKING, ClassVar
4
5
# LiteralString is from Python 3.11;
6
# atm, we want to support Python 3.9
@@ -74,7 +74,7 @@ def attributes(self):
74
raise AttributeError("Attributes is write-only by design")
75
76
@attributes.setter
77
- def attributes(self, attributes: Any):
+ def attributes(self, attributes: dict):
78
"""Publish the JSON attributes of this entity."""
79
self.publish_mqtt_message(bytes(json.dumps(attributes), "utf-8"), "attrs")
80
0 commit comments