mirror of
https://github.com/migatu/conjurer.git
synced 2026-07-14 21:38:38 +00:00
fx
This commit is contained in:
@@ -205,16 +205,16 @@ class Transcriber(commands.Cog):
|
||||
logger.info("waiting for tasks")
|
||||
item = await self.comm_queue.get()
|
||||
logger.info("Got %s", item)
|
||||
if item.type == "STOP":
|
||||
if "STOP" in item.type:
|
||||
logger.info("Queue ended")
|
||||
break
|
||||
elif item.type == "send_file":
|
||||
elif "send_file" in item.type:
|
||||
transcript = ""
|
||||
for iter in item.data:
|
||||
transcript = transcriber.transcribe(iter, config=config)
|
||||
for utterance in transcript.utterances:
|
||||
logger.info("%s : %s", item.user, utterance.text)
|
||||
elif item.type == "user_cleanup":
|
||||
elif "user_cleanup" in item.type:
|
||||
logger.info("User %s disconnected - cleanup action")
|
||||
else:
|
||||
logger.warn("Something went wrong with object %s", item)
|
||||
|
||||
Reference in New Issue
Block a user