sochix / TLSharp

Telegram client library implemented in C#
1k stars 380 forks source link

InvalidOperationException after calling GetUserDialogs #841

Open zarEclEC opened 5 years ago

zarEclEC commented 5 years ago
  at TLSharp.Core.Network.MtProtoSender.HandleRpcResult (System.UInt64 messageId, System.Int32 sequence, System.IO.BinaryReader messageReader, TeleSharp.TL.TLMethod request) [0x001a5] in C:\git\TLSharp\TLSharp.Core\Network\MtProtoSender.cs:319 
  at TLSharp.Core.Network.MtProtoSender.ProcessMessage (System.UInt64 messageId, System.Int32 sequence, System.IO.BinaryReader messageReader, TeleSharp.TL.TLMethod request) [0x001c8] in C:\git\TLSharp\TLSharp.Core\Network\MtProtoSender.cs:201 
  at TLSharp.Core.Network.MtProtoSender+<Receive>d__8.MoveNext () [0x000d0] in C:\git\TLSharp\TLSharp.Core\Network\MtProtoSender.cs:139 
--- End of stack trace from previous location where exception was thrown ---
  at TLSharp.Core.TelegramClient+<RequestWithDcMigration>d__10.MoveNext () [0x000ed] in C:\git\TLSharp\TLSharp.Core\TelegramClient.cs:119 
--- End of stack trace from previous location where exception was thrown ---
  at TLSharp.Core.TelegramClient+<SendRequestAsync>d__18`1[T].MoveNext () [0x00026] in C:\git\TLSharp\TLSharp.Core\TelegramClient.cs:225 
--- End of stack trace from previous location where exception was thrown ---
  at TLSharp.Core.TelegramClient+<GetUserDialogsAsync>d__22.MoveNext () [0x0009e] in C:\git\TLSharp\TLSharp.Core\TelegramClient.cs:281 
--- End of stack trace from previous location where exception was thrown ---
  at ArmeGram.ChatList+<Update_DialogsAsync>d__2.MoveNext () [0x0005b] in C:\git\ArmeGram\ArmeGram_3\ChatList.cs:138 

AUTH_KEY_UNREGISTERED

lazyjohny500 commented 5 years ago

Please try to test your request without any channels on your dialogs. I have a theory that these problems are because of the channels, It's happen to me while trying to get files of channels too.

zarEclEC commented 5 years ago

I don't decide which dialogs I'm gonna get

lazyjohny500 commented 5 years ago

Yes I know, But just for testing that theory, so we will say for sure that this is the problem. Just make a test account with dialogs -- without channels... And check if then its working for you.

zarEclEC commented 5 years ago

I don't have the numbers to make a test account

nimix3 commented 5 years ago

Hello,

AUTH_KEY_UNREGISTERED is according to Telegram server error, Your current session invalidates by Telegram, it happens when Telegram found that you SPAM somewhere or also in false positive on virtual numbers!

nimix3 commented 5 years ago

Also, old layers and public AppID or Apphash cause such problems, It is better to use OpenTI project with MTProto V2 and new layer.

zarEclEC commented 5 years ago

@nimix3 where can I fine openTI project?

nimix3 commented 5 years ago

@ArmeF97 https://github.com/sochix/TLSharp/issues/834