Open Lucasquattro opened 2 months ago
Subject: Update on the Telegram to WhatsApp Chat Converter Script
Hey Lucasquattro,
Thanks for letting me know about the issue with the script producing a blank _chat.txt
file. I took a closer look, and it turns out the problem was due to a difference in how the Telegram export JSON was structured.
The script was originally set up to work with Telegram exports where the messages
were right at the root of the JSON file. But in your export, the messages
were actually nested under chats -> list -> [0]
. Because of this, the script couldn’t find the messages and ended up generating an empty file.
I’ve updated the script to handle this kind of nested structure. Now, it checks for messages
both at the root level and within the chats
section, so it should work no matter where the messages are located in your export file.
Go ahead and try running the updated script with your Telegram export. It should now create the _chat.txt
file with all your chat content formatted for WhatsApp.
I really appreciate you pointing this out, and I hope this fix does the trick. If you run into any other issues or have more feedback, just let me know.
Cheers,
Suberbia
Hi there, I tried the script but unfortunately the output is an empty _chat.txt file. I tried with different json output and tried also to simplify to a single message to understand if n° messages was a limit. Nothing changed.
I'm on mac, python3 and brew all updated to last versions, idk where I miss something. Below example of json used:
Many thanks!