Open JRavi2 opened 2 years ago
In which format should I provide the Telegram test data : Text file or JSON?
@asaraf7 JSON would be fine. Should I assign this issue to you, if you'd like to work on it?
I have an idea. I'll create 5 Telegram bots and add them in a group. Then I'll send say 10000 Test Messages using python requests module. Shall I proceed with this?
The problem with this approach would be that the results generated through this would be too unnatural, and wouldn't represent a real-world scenario (even if you sent the messages randomly).
My recommendation would be to get a chat export from an actual telegram group with a sufficient number of messages. Also, you could write a simple script to replace usernames with A, B, C, D... and redact the messages.
I'm writing a script as suggested by you. But for that I'll have to open and decode the original json. It raises an exception while reading emojis. How to handle that?
@asaraf7 Could you share the error message?
I think the exception might be due to the encoding. Try passing encoding='utf-8'
parameter to the open function.
@asaraf7 Could you share the error message?
I think the exception might be due to the encoding. Try passing
encoding='utf-8'
parameter to the open function.
Implemented and PR has been sent!
Currently, there are tests for Signal and WhatsApp. Similarly, tests for Telegram Exports are to be added.