File: exceptions.py

package info (click to toggle)
switchbot-api 2.7.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 312 kB
  • sloc: python: 591; makefile: 20
file content (17 lines) | stat: -rw-r--r-- 405 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
"""Exceptions for the SwitchBot API."""


class SwitchBotError(Exception):
    """General SwitchBot error occurred."""


class SwitchBotConnectionError(SwitchBotError):
    """Cannot connect to the SwitchBot API."""


class SwitchBotAuthenticationError(SwitchBotError):
    """Invalid auth for the SwitchBot API."""


class SwitchBotDeviceOfflineError(SwitchBotError):
    """Device currently offline."""