Enhance TwitchBot message sending by integrating event loop management. Updated send_twitch_message to utilize the existing event loop for asynchronous message sending, improving reliability and error handling. Added timeout handling for message sending operations.
This commit is contained in:
@@ -158,8 +158,10 @@ def _isConfigured():
|
||||
|
||||
class TwitchBot():
|
||||
_eventsub = None
|
||||
_loop = None
|
||||
|
||||
async def _connect(self):
|
||||
self._loop = asyncio.get_event_loop()
|
||||
with webapp.app_context():
|
||||
if _isConfigured():
|
||||
try:
|
||||
|
||||
Reference in New Issue
Block a user