joeyates / imap-backup

Backup and Migrate IMAP Email Accounts
MIT License
1.33k stars 74 forks source link

Ignoring unparsable header #174

Closed julpec closed 9 months ago

julpec commented 9 months ago

When I tried to migrate, I couldn't transfer the previously backup emails correctly. The backup command did not return an error. However, when migrating to another provider, I get a huge number of errors like this:

WARNING: Ignoring unparsable header "Grande,Geneva,Verdana,sans-serif; font-size:16px; font-weight:400;\n                                                          line-height:1.3;\n                                                          margin:0;\n                                                          padding:0;\n                                                          text-align:left\">\n                                                          <center\n                                                          style=\"min-width:490px;\n                                                          width:100%\">\n                                                          <table\n                                                          class=\"button\n                                                          btn default\n                                                          primary\n                                                          float-center\"": invalid header name syntax: "Grande,Geneva,Verdana,sans-serif; font-size"
WARNING: Ignoring unparsable header "J'ai rempli le frama :)": invalid header name syntax: "J'ai rempli le frama"

It seems to look for a header in every line of the .mbox file.

joeyates commented 9 months ago

Hi @julpec

Thanks for opening the issue. I suspect that the backup maybe malformed due to a recently resolved bug. If the mails are still available on the source server, I suggest moving the old backups to a different location and re-running the backup.

If this does not resolve the issue and you still have problems with the migrate command, please run it with the --verbose parameter and send me the redacted output.

julpec commented 9 months ago

Yes !! It works \o/

I still have this error reported when I migrate :

 append error: undefined method `uidvalidity'

Don't know if it's a problem… I did what @maty974 did in #140 renaming the ruby library file and there is no error reported.

joeyates commented 9 months ago

Hi @julpec

I think

undefined method `uidvalidity'

is a different problem.

Could you open an issue for that?