From 8d0c65ad56bae5266ef9f67f88fe47ab78353965 Mon Sep 17 00:00:00 2001 From: rospogrigio Date: Mon, 28 Sep 2020 15:08:04 +0200 Subject: [PATCH] Restored missing docstring for TuyaDevice.set_dps() --- custom_components/localtuya/common.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/custom_components/localtuya/common.py b/custom_components/localtuya/common.py index 4c8e259..5deda9a 100644 --- a/custom_components/localtuya/common.py +++ b/custom_components/localtuya/common.py @@ -89,6 +89,7 @@ class TuyaDevice: raise ConnectionError("Failed to update status .") def set_dps(self, state, dps_index): + """Changes the value of a DP of the Tuya device, and update the cached status.""" # _LOGGER.info("running def set_dps from TuyaDevice") # No need to clear the cache here: let's just update the status of the changed dps as returned by the interface (see 5 lines below) # self._cached_status = "" @@ -116,7 +117,7 @@ class TuyaDevice: # raise ConnectionError("Failed to set status.") def status(self): - """Get state of Tuya switch and cache the results.""" + """Get the state of the Tuya device and cache the results.""" _LOGGER.debug("running def status(self) from TuyaDevice") self._lock.acquire() try: