Closed devtunnelx closed 2 months ago
What are you trying to achieve exactly?
You're not supposed to call manager.CollectUsersChats
What are you trying to achieve exactly?
You're not supposed to call manager.CollectUsersChats
Basically, my app listen to incoming Telegram updates and I want to get the sender and chat information from the update then enqueue it to be processed by queue consumers.
If using manager.CollectUsersChats
is not the right way, what would you suggest?
thank you sir
Use Manager.UserOrChat
or Manager.Users
/Chats
dictionaries to resolve peers & ids into details
or call structure.CollectUsersChats(Manager.Users, Manager.Chats);
after an API call that return a structure which contains users/chats
As demonstrated in https://github.com/wiz0u/WTelegramClient/blob/master/Examples/Program_ListenUpdates.cs
See also these explanations:
Version: 4.1.2-dev.7
I'm having an issue when using
UpdateManager.CollectUsersChats()
Exception keeps thrown after running the app (like 30 minutes or 45 later)
Collection was modified; enumeration operation may not execute.
Current code:
Even when using _lock and thread safety masques, i still get the error at
manager.CollectUsersChats(users, chats);