rgladwell / imap-upload

Python script for uploading a local mbox file to IMAP4 server.
Other
129 stars 30 forks source link

E-mail duplication on second run #67

Closed lmateovf closed 4 months ago

lmateovf commented 4 months ago

Hello! I backed up an mbox (via Google Takeout) to migrate 89,000 emails from one account to another.

Due to an issue, I interrupted the script's process, and now I want to know if running it again will duplicate the emails. My command is as follows:

python imap_upload.py --ssl --user=new_account@gmail.com --password="password" --host=imap.gmail.com --port=993 --dry-run --error="errores.mbox" --google-takeout "original.mbox"

Thank you in advance for your help, and for building this great tool!

rgladwell commented 4 months ago

Running again will duplicate messages. In future, I suggest using the dry run mode.

lmateovf commented 4 months ago

Hey, thanks for the fast response but judging from this image it seems it is continuing were it stopped:

It shows that is not uploading from the very first mail again... I just started re-running the script... are you sure it will duplicate emails?

Captura 2024-04-01 a las 12 25 26

If it is going to duplicate them it's no problem because we have enough storage... Could you refer any tool that handles gmail duplicates? I can search of course, but maybe you can recommend me one...

rgladwell commented 4 months ago

Perhaps Google Takeout has some kind of feature that avoids duplication?