-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
RPC login error #3215
Comments
This comment has been minimized.
This comment has been minimized.
I have a similar problem on Windows 11 and I can also replicate it on Ubuntu 20.04.
It only appears when I try to login with phone number. But there was no problem yesterday. |
Facing the same issue on AWS EC2, based on CentOS. This was working fine few hours ago. I got this error, when I opened up a new session, while I had 3 existing sessions already. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
The library must be updated. I will try to find time to do so as soon as possible (at least so that login works…). Previous sessions should be okay for a bit longer. Thank you all for your patience. If you have the same issue, please react with a thumbs-up (👍) emoji to the original post rather than posting another comment to avoid notifying everyone. I will post updates in this thread. Telegram has started enforcing the use of 64-bit identifiers for users and chats, and the current stable version of the library does not support them yet. If you try to login, you may see I will try to find time to update the library as soon as possible. Although the first version supporting this new layer may not be as well-tested as I would've liked (because I haven't had much time to devote to open source lately). Thank you for your patience. If you want to stay updated, please subscribe to this GitHub thread. old fix, read further comments for current solutionIf someone desperatily needs this fix, please uninstall
(You may also use a virtual environment.) |
Here are some additional questions people have asked, and the answers: How does Telegram know if Telethon supports 64-bit IDs or not? Telegram has a concept known as "layers", allowing old apps to remain working on old layers, and new apps using new layers to enjoy new changes. The current stable version of Telethon has an old layer. Telegram has "split" the layers and left old ones no longer working probably because recent changes have made it very hard to remain backward-compatible (changing user identifiers from 32 to 64 bits is a pretty big change). After the library updates will the previous session be compatible/usable or will they become invalid? Previous session files should remain valid (Telethon will still understand them), but it's not possible to know if Telegram will revoke them for other reasons (although it shouldn't). Does this issue affect bots too? Yes, bots also need to "login" to work with the API, using a bot token, so they also can get the error. If I have userbot running, until I restart, it should (probably) be okay? Existing sessions (and sessions currently in use) should be fine. Will Telethon add block ads? The library will not block sponsored messages. Doing so is against Telegram's Terms of Service. If you develop an application using Telethon, you must comply with them, or risk getting your account banned in some way.
When will a fix be published? I will try to do this as soon as possible, but because the release will be rushed, bugs may be present. If this is the case, please be sure to report them (or vote if they already exist). For a temporary workaround, please refer to #3215 (comment). |
can this be fixed today please? |
Hi Will we have to modify the codes of all our scripts using Telethon? Thanks ! |
how please? |
no, telethon will take care of compatibility. only if you made stupid assumptions like userd-id will never bigger than 2,147,483,647 you may have to change your script. |
This comment has been minimized.
This comment has been minimized.
I have pushed v1.24 to PyPi, which fixes login (thus avoiding It contains two more hot-fixes (and the "latest" 133 layer, to prevent receiving broken constructors), but not the latest layer, currently 135, to avoid breaking more things than necessary). Note that if you uninstalled Thank you for your patience and understanding. Please be aware that this new version uses 64 bit identifier for users, chats, and more. You may need to update your code to handle this correctly. |
1 - Thanks for the work @Lonami! It really helps a lot! |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Sadly does not work for me |
@joaopedrolourencoaffonso yes, I can notify about future versions here (if I remember). Regarding security, I'm not sure what you're asking. There have been no security issues that I know of in the previous or current version. You can ask me privately about this if you know something. @BramGamingNL please make sure you've successfully installed the latest version (verify that |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
I just solved this issue by: |
Hi, I got the same issue on my RPI4 with yunohost to use telegramebot with Mautrix_telegram. LOG :
Did I miss something ? More info : Thx |
C:\Users\Anderson>pip install -U telethon --no-cache continuo com o mesmo problema poderia me ajudar, pois nao consigo logar telegram |
I have the same error (406 UPDATE_APP_TO_LOGIN) in python scripts attempting to login to Telegram :( I upgraded Telethon to ver. 1.24.0 but it didn't solve the problem. |
Please take care that your script is using the correct version. To verify add print the telethon version in your bot script right after the "import telethon" statement and run your script as usual, .e.g. import telethon
print('Telethon Version used: '+telethon.__version__)
quit() this should output: |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Thank you all. Fixed the problem and now the new sessions work fine. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Described in LonamiWebs/Telethon#3215 Reported in Drakkar-Software/OctoBot#1901
Described in LonamiWebs/Telethon#3215 Reported in Drakkar-Software/OctoBot#1901
This comment has been minimized.
This comment has been minimized.
v2 is still in the works, primarily, proxies and entity still needs some work, but it's getting there. People interested in knowing when more updates are made can follow https://t.me/TelethonUpdates. |
Any help on this please Traceback (most recent call last): |
help me please @Lonami Input session name: sasaas
|
I solved making visible to anyone the telegram profile picture. |
Hello dear @ I fixed this to |
Hi how are you |
telethon.errors.rpcbaseerrors.AuthKeyError: RPCError 406: UPDATE_APP_TO_LOGIN (caused by SignInRequest)
I am getting this error, anyone know the problem? Ubuntu 20.04 fresh install & can also replicate on macOS
The text was updated successfully, but these errors were encountered: