backup_gmail.py fails with "No such file or directory: '/data/gmail-backup/(added/by'"
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Backup Gmail |
New
|
Undecided
|
Unassigned |
Bug Description
Hi
First: Thanks for a great tool, it's really needed and I'm sure the following is either a fault from my side or an easy fixable bug.
First I ran a full backup using gui.py to a writable partition with settings noincremental and not to keep read/unread (maybe give a little warning if people doesn't check that - it was a mistake that I didn't check it. Well, my bad ;)
The backup ran without problems so I let it write the config to a file:
$ cat .gmail-backup.cfg
[Main]
username = <email address hidden>
password = xxxxxxxx
backup_dir = /data/gmail-backup
keep_read = True
incremental = True
Then a ran:
~/bin/backup-
which after running for a while and backing up several folders gave this error:
Traceback (most recent call last):11/12346490]
File "/home/
doBackup(
File "/home/
backup.
File "/home/
self.
File "/home/
self.
File "/home/
self.
File "/home/
self.
File "/home/
self.
File "/home/
with open('%s/%s/%s' % (dest, self.folder, self.hash_value)) as f:
IOError: [Errno 2] No such file or directory: '/data/
I ran it again with the setting "incremental = False" and pressed yes to overwriting the folder. That went fine, but running it afterwards again with "incremental = True" gave the above error.
I'm using version 0.1.2.1
Best Regards
Thomas Olsen
The problems comes from emails with a Message-ID in the header like
Message-ID: <email address hidden> (added by <email address hidden>)
which are parsed wrongly. I'll try to write a patch.