I keep getting same errors when trying to rerun Telethon script

Viewed 41

so i`m trying to learn Telethon and wrote some script from tutorial. It works fine for the first time, when i have to confirm authorization.

from telethon import TelegramClient

api_id = 1234567
api_hash = ''
client = TelegramClient('anon', api_id, api_hash)


async def main():
    me = await client.get_me()
    print(me.username)
    

with client:
    client.loop.run_until_complete(main())

but when i try to run it again with the same .session file i keep getting same error, which doesn`t help to understand the problem.

Server sent a very new message with ID 7144059125492611077, ignoring
Server sent a very new message with ID 7144059125964561409, ignoring

Also, program doesn`t stop running after this error.

1 Answers

After a couple of days searching for a fix, i just switched to pyrogram, which works perfectly fine. So if someone got the same problem I recommend just to change Telethon to something else.

Related