Похожие чаты

But will it “unlock” from client.disconnected? Cause I’ve added sys.exit()

below and the script seems to just keep running after AuthKeyUnregisteredError

11 ответов

12 просмотров

Documentation for disconnected

first use await client.run_until_disconnected() than await client.disconnected, it may handle some extra things and you don't need to use sys.exit(). just let the interpreter leave cleanly and handle the raised error once library crashes show the logs when you reproduce that behavior if run_until_disconnected is same

goldsopin- Автор вопроса
⎞ .·. ⎝ ⎝
first use await client.run_until_disconnected() th...

2023-09-03 22:12:07,547 - INFO - TELEGRAM-CLIENT: awaiting self.client.run_until_disconnected()2023-09-03 22:12:14,110 - INFO - TELEGRAM-CLIENT.client.updates: Cannot get difference since the account is not logged in: AuthKeyUnregisteredError still not exiting

goldsopin
screenshot 2023-09-03 22:12:07,547 - INFO - TELEGRAM-CLIENT: ...

mehh, does it keep logging forever or it goes silent, you sure it's not raising?

goldsopin- Автор вопроса
⎞ .·. ⎝ ⎝
mehh, does it keep logging forever or it goes sile...

Just silent I’ve tried waiting 5 mins but no new logs

can you confirm it's not raising anything try: await client.run_until_disconnected() except: logger.info('run_until_disconnected Raised')

goldsopin
screenshot 2023-09-03 22:12:07,547 - INFO - TELEGRAM-CLIENT: ...

awaiting of client.run_until_disconnected() just blocking asyncio event loop this function should be like entry point, and to disconnect from your error you need put your code into try except: try: await self.cl.run_until_disconnected() except AuthKeyError: await self.client.disconnect()

goldsopin- Автор вопроса
goldsopin
Same result ...

I've noticed now that if i sign in and directly terminate session from my phone it doesn't raise error but if i sign in > log out > sign in > terminate it raises error

goldsopin
Same result ...

Since it's not raising you're doing something weird that messes with the library logic of raising, probably the was_once_logged_in. looking at how start() doesn't ask you for phone input, means you're authorized at start in the .session file, but since Updates handling is failing while running, you need to show more info on what you're doing with latest full code after to reproduce it. it's mostly a side effect of catch_up

goldsopin- Автор вопроса

Похожие вопросы

Обсуждают сегодня

Господа, а что сейчас вообще с рынком труда на делфи происходит? Какова ситуация?
Rꙮman Yankꙮvsky
29
А вообще, что может смущать в самой Julia - бы сказал, что нет единого стандартного подхода по многим моментам, поэтому многое выглядит как "хаки" и произвол. Короче говоря, с...
Viktor G.
2
@Benzenoid can you tell me the easiest, and safest way to bu.y HEX now?
Živa Žena
20
This is a question from my wife who make a fortune with memes 😂😂 About the Migration and Tokens: 1. How will the old tokens be migrated to the new $LGCYX network? What is th...
🍿 °anton°
2
30500 за редактор? )
Владимир
47
а через ESC-код ?
Alexey Kulakov
29
What is the Dex situation? Agora team started with the Pnetwork for their dex which helped them both with integration. It’s completed but as you can see from the Pnetwork ann...
Ben
1
Гайс, вопрос для разносторонее развитых: читаю стрим с юарта, нада выделять с него фреймы с определенной структурой, если ли чо готовое, или долбаться с ринг буффером? нада у...
Vitaly
9
Anyone knows where there are some instructions or discort about failed bridge transactions ?
Jochem
21
@lozuk how do I get my phex copies of my ehex from a atomic wallet, to move to my rabby?
Justfrontin 👀
11
Карта сайта