miio.exceptions module
- exception miio.exceptions.CloudException[source]
Bases:
ExceptionException raised for cloud connectivity issues.
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- args
- exception miio.exceptions.DeviceError(error)[source]
Bases:
DeviceExceptionException communicating an error delivered by the target device.
The device given error code and message can be accessed with code and message variables.
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- args
- exception miio.exceptions.DeviceException[source]
Bases:
ExceptionException wrapping any communication errors with the device.
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- args
Bases:
DeviceExceptionException raised when requesting miio.info fails.
This allows users to gracefully handle cases where the information unavailable. This can happen, for instance, when the device has no cloud access.
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception miio.exceptions.InvalidTokenException[source]
Bases:
DeviceExceptionException raised when invalid token is detected.
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- args
- exception miio.exceptions.PayloadDecodeException[source]
Bases:
DeviceExceptionException for failures in payload decoding.
This is raised when the json payload cannot be decoded, indicating invalid response from a device.
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- args
- exception miio.exceptions.RecoverableError(error)[source]
Bases:
DeviceErrorException communicating a recoverable error delivered by the target device.
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- args
- exception miio.exceptions.UnsupportedFeatureException[source]
Bases:
DeviceExceptionException communicating that the device does not support the wanted feature.
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- args