bot runs in loops and... the users aren't being unique <3
This commit is contained in:
parent
08c231209c
commit
1ac5f5c1f7
15
bot/main.py
15
bot/main.py
|
|
@ -152,5 +152,18 @@ async def process_chats():
|
|||
await post_chat_update(session, chat_object, fresh_xsrf_token)
|
||||
|
||||
|
||||
async def main_loop():
|
||||
while True:
|
||||
try:
|
||||
await process_chats()
|
||||
await asyncio.sleep(10)
|
||||
|
||||
except asyncio.CancelledError:
|
||||
print("cancelled normally (ok knowing my luck the error is gonna be this one every single time even tho it never actually is an error like this!) cute puppy: Hiiii")
|
||||
break
|
||||
except Exception as e:
|
||||
print(f"error {e}")
|
||||
await asyncio.sleep(10)
|
||||
|
||||
if __name__ == "__main__":
|
||||
asyncio.run(process_chats())
|
||||
asyncio.run(main_loop())
|
||||
|
|
|
|||
|
|
@ -1,6 +1,19 @@
|
|||
@livewireStyles
|
||||
|
||||
<flux:main>
|
||||
<!--
|
||||
######
|
||||
#### ### ####
|
||||
## ## ## ##
|
||||
## ## ## ##
|
||||
## ## ### ##
|
||||
## ## ## ##
|
||||
## ## ## ##
|
||||
#### ##########
|
||||
###### ##
|
||||
### ###
|
||||
########
|
||||
-->
|
||||
{{ $slot }}
|
||||
</flux:main>
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue