Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions adafruit_io/adafruit_io.py
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,8 @@ def _on_message_mqtt(self, client, topic, payload):
messages.append(payload)
topic_name = feeds
message = messages
elif topic_name[1] == "throttle":
raise AdafruitIO_ThrottleError(payload)
elif topic_name[0] == "time":
# Adafruit IO Time Topic
topic_name = topic_name[1]
Expand Down
8 changes: 1 addition & 7 deletions adafruit_io/adafruit_io_errors.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,13 +28,7 @@


class AdafruitIO_ThrottleError(Exception):
"""Adafruit IO request error class for rate-limiting"""

def __init__(self):
super().__init__(
"Number of Adafruit IO Requests exceeded! \
Please try again in 30 seconds.."
)
"""Adafruit IO request error class for rate-limiting."""


class AdafruitIO_RequestError(Exception):
Expand Down