File: exceptions.py

package info (click to toggle)
python-plugwise 1.7.8-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 6,072 kB
  • sloc: xml: 90,058; python: 5,265; sh: 324; makefile: 2
file content (45 lines) | stat: -rw-r--r-- 1,110 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
"""Plugwise Smile Exceptions."""


class PlugwiseException(Exception):
    """Base error class for this Plugwise library."""


class ConnectionFailedError(PlugwiseException):
    """Raised when unable to connect."""


class DataMissingError(PlugwiseException):
    """Raised when expected data is missing."""


class InvalidAuthentication(PlugwiseException):
    """Raised when unable to authenticate."""


class InvalidSetupError(PlugwiseException):
    """Raised when adding an Anna while an Adam exists."""


class PlugwiseError(PlugwiseException):
    """Raise when a non-specific error happens."""


class UnsupportedDeviceError(PlugwiseException):
    """Raised when device is not supported."""


class DeviceSetupError(PlugwiseException):
    """Raised when device is missing critical setup data."""


class ResponseError(PlugwiseException):
    """Raised when empty or error in response returned."""


class InvalidXMLError(PlugwiseException):
    """Raised when response holds incomplete or invalid XML data."""


class XMLDataMissingError(PlugwiseException):
    """Raised when xml data is empty."""