fix(channels): retain scheduled results across pre-send outages
This commit is contained in:
1 parent
61db036cee
commit
508cedff31
31 files changed
+768
-61
No files matched your search
@@ -13,6 +13,7 @@ from typing import TYPE_CHECKING, Any, Literal, cast
|
||||
|
||||
from pydantic import Field
|
||||
|
||||
from nanobot.bus.delivery import ChannelNotReadyError
|
||||
from nanobot.bus.events import OutboundMessage
|
||||
from nanobot.bus.outbound_events import ContextCompactionEvent, ProgressEvent
|
||||
from nanobot.bus.queue import MessageBus
|
||||
@@ -539,7 +540,7 @@ class DiscordChannel(BaseChannel):
|
||||
"""Send a message through Discord using discord.py."""
|
||||
client = self._client
|
||||
if client is None or not client.is_ready():
|
||||
raise RuntimeError("Discord client is not ready")
|
||||
raise ChannelNotReadyError("Discord client is not ready")
|
||||
|
||||
is_progress = isinstance(msg.event, ProgressEvent)
|
||||
|
||||
|
||||
Reference in new issue
Block a user