Open xlccccc opened 4 months ago
i'm currently having same issue, except im trying to run code on google cloud vm. it works perfectly on my machine, its stuck i same place as yours on vm.
Something going on with the Telegram APIs maybe...
Was receiving the unhelpful Server sent a very new message with ID 7410434973273745413, ignoring (see FAQ for details)
.
Thanks for the logging hint, getting similar debug logs but a bit more lines...
DEBUG:asyncio:Using proactor: IocpProactor
INFO:telethon.network.mtprotosender:Connecting to 149.154.167.91:443/TcpFull...
DEBUG:telethon.network.mtprotosender:Connection attempt 1...
DEBUG:telethon.network.mtprotosender:Connection success!
DEBUG:telethon.network.mtprotosender:Starting send loop
DEBUG:telethon.network.mtprotosender:Starting receive loop
INFO:telethon.network.mtprotosender:Connection to 149.154.167.91:443/TcpFull complete!
DEBUG:telethon.network.mtprotosender:Waiting for messages to send...
DEBUG:telethon.extensions.messagepacker:Assigned msg_id = 7410435962950057644 to InvokeWithLayerRequest (175b3260810)
DEBUG:telethon.network.mtprotosender:Encrypting 1 message(s) in 76 bytes for sending
DEBUG:telethon.network.mtprotosender:Encrypted messages put in a queue to be sent
DEBUG:telethon.network.mtprotosender:Waiting for messages to send...
DEBUG:telethon.network.mtprotosender:Receiving items from the network...
DEBUG:telethon.network.mtprotosender:Handling bad salt for message 7410435962950057644
DEBUG:telethon.network.mtprotosender:1 message(s) will be resent
DEBUG:telethon.network.mtprotosender:Receiving items from the network...
DEBUG:telethon.extensions.messagepacker:Assigned msg_id = 7410435963239099160 to InvokeWithLayerRequest (175b3260810)
DEBUG:telethon.network.mtprotosender:Encrypting 1 message(s) in 76 bytes for sending
DEBUG:telethon.network.mtprotosender:Encrypted messages put in a queue to be sent
DEBUG:telethon.network.mtprotosender:Waiting for messages to send...
DEBUG:telethon.extensions.messagepacker:Assigned msg_id = 7410435963249613420 to MsgsAck (175af519810)
DEBUG:telethon.network.mtprotosender:Encrypting 1 message(s) in 36 bytes for sending
DEBUG:telethon.network.mtprotosender:Encrypted messages put in a queue to be sent
DEBUG:telethon.network.mtprotosender:Waiting for messages to send...
WARNING:telethon.network.mtprotostate:Server sent a very new message with ID 7410436216796687365, ignoring (see FAQ for details)
DEBUG:telethon.network.mtprotosender:Receiving items from the network...
WARNING:telethon.network.mtprotostate:Server sent a very new message with ID 7410436216857783297, ignoring (see FAQ for details)
DEBUG:telethon.network.mtprotosender:Receiving items from the network...
Running the sync code from the readme basically, posting here for contrast.
from telethon import TelegramClient, events, sync
import logging
logging.basicConfig(level=logging.DEBUG)
api_id = 0
api_hash = '0'
client = TelegramClient('session_name', api_id, api_hash)
client.start()
Steps to reproduce:
Windows 10 Python 3.11.9 Telethon 1.36.0
Well , basically allowing to go forward after Server sent a very new message...
makes the client to work, it seems, at least for getting messages.
Just removed the return None
after the message warnings are printed in network /mtprotostate.py
i'm currently having same issue, except im trying to run code on google cloud vm. it works perfectly on my machine, its stuck i same place as yours on vm.
Did you solve it?
Runs perfectly fine on my local machine but gets stuck on my server
Nope , I dropped it, I suspect there was an issue with Google blocking certain ips even tho I unlocked everything in firewall. I just used different server provider
Code that causes the issue
Expected behavior
Telegram received the verification code and successfully logged in after entering it
Actual behavior
Stuck when logging in
Traceback
No response
Telethon version
1.36
Python version
3.9.13
Operating system (including distribution name and version)
Windows 10
Other details
The log is stuck here all the time and no error is reported
Checklist
pip install -U https://github.com/LonamiWebs/Telethon/archive/v1.zip
and triggered the bug in the latest version.