Working 6.3.4 config breaks in 18.104.22.168
mike at pentangle.net
Mon Feb 13 16:40:38 GMT 2012
thanks to all who quickly spotted the problem, and for the configuration changes.
On 13 Feb 2012, at 17:00, Daniel Shahaf wrote:
Sebastian Spaeth wrote on Mon, Feb 13, 2012 at 14:47:59 +0100:
>> On Fri, 10 Feb 2012 14:11:41 +0100, Michael Williams wrote:
>>> [Repository remotempe]
>>> nametrans = lambda foldername: re.sub('^INBOX.', '', foldername)
>> So your remote repository cuts off the initial INBOX., you'll need to
>> append them from your local repository so that offlineimap is able to
>> find the corresponding mapping (nametrans is one-way only...)
>> I'd suggest something like:
>> [Repository localmpe]
>> type = Maildir
>> localfolders = ~/.mail/mpe
>> nametrans = lambda folder: "INBOX." + folder
>> Would that work for you?
> It'll break when the remote folder name is "INBOX".
> nametrans = lambda f: ["INBOX."+f, f][f == "INBOX"]
I can figure out roughly what Sebastian's (and Jonas Hörsch's) suggestion does, but I don't speak Python, so I don't understand how Daniel's works. But in any case I tried both of these. I synced using 6.3.4 then inserted each line into my offlineimaprc and then ran 22.214.171.124. In both cases, offlineimap copied new messages (i.e. negative message index) from the local repository to the remote. This didn't seem right, given I had just synced, so I aborted the process.
Since I am, in principle, risking data loss here, I would be very grateful for some clarification and reassurance! Which one of these snippets is right? Should my first 126.96.36.199 session result in data transfer?
More information about the OfflineIMAP-project