mirror of
https://github.com/migatu/conjurer.git
synced 2026-07-14 21:38:38 +00:00
aa
This commit is contained in:
@@ -588,7 +588,7 @@ async def check_data():
|
||||
# trunk-ignore(codespell/misspelled)
|
||||
# TODO: dlaczego sie tu wypierdala
|
||||
logger.info("Heartbeat of cleanup proc")
|
||||
channel = client.get_channel(1062047571557744721)
|
||||
channel = client.get_channel(1062047367337095268)
|
||||
messages = [message async for message in channel.history(limit=1)]
|
||||
for mess in messages:
|
||||
channel = mess.channel
|
||||
@@ -651,10 +651,14 @@ async def check_data():
|
||||
logger.info(tdelta)
|
||||
global TIME_BETWEEN_CALLS
|
||||
if tdelta > TIME_BETWEEN_CALLS:
|
||||
TIME_BETWEEN_CALLS = 600 #temp
|
||||
logger.info("Spontaneous call")
|
||||
TIME_BETWEEN_CALLS = 60000 #temp random, set after each call
|
||||
logger.info(TIME_BETWEEN_CALLS)
|
||||
LAST_SPONTANEOUS_CALL = datetime.now()
|
||||
async with channel.typing():
|
||||
message = await get_random_cyclic_message()
|
||||
logger.info("Odpowiedz")
|
||||
logger.info(message)
|
||||
await channel.send(message)
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user