СУ
Size: a a a
СУ
s
СУ
NK
NK
NK
K0
СУ
СУ
СУ
K0
s
СУ
import logging
logging.basicConfig(level=logging.DEBUG)
from threading import Thread as T
from telethon import TelegramClient as C
from telethon.events import NewMessage
import asyncio
from con import aid, ahash, t1, t2
async def t():
c1 = C(None, aid, ahash)
await c1.start(bot_token=t1)
c2 = C(None, aid, ahash)
await c2.start(bot_token=t2)
async def a(b):
await b.reply('b')
c1.add_event_handler(NewMessage, a)
c2.add_event_handler(NewMessage, a)
def tt(k):
asyncio.set_event_loop(k)
k.run_until_complete(t())
k.run_forever()
l = asyncio.new_event_loop()
T(target=tt, args=(l,)).start()
s
СУ
СУ
s
s
NK