Automatic reconnection

Assigned to
1 year, 11 months ago
a month ago

~dxu 1 year, 7 months ago


Would be nice to not have to restart aerc after closing the laptop lid.

~halosan 1 year, 5 months ago

Is quitting and restarting aerc the only way to reconnect to IMAP after disconnect (either network related or the computer goes to sleep)?

~labrat 1 year, 5 months ago

As of now yes. But that's just because no one took the time to remedy that, not due to a design decision.

So in short, write a patch please ? :)

~otheb referenced this from #315 1 year, 5 months ago

~clarkema 4 months ago

I've just been bitten by this due to a temporary network outage. I spent most of the evening on and off composing a long epic response to a thoughtful mail. While I was doing so my network flapped a few times, but I thought nothing of it. When I came to actually send the mail... no dice. Vim closed normally, the temp file was deleted, and I was then informed that I had no connection to my SMTP server.

I tried to recreate this by sending a mail when my network was artificially down and encountered a similar failure, but at least in that case the email was left in /tmp and could be retrieved. Not so with the one I actually care about.

I've lost an evening's thought, which I will have to try and recreate tomorrow, with no warning.

I admit I haven't looked at the code, but if graceful reconnection is difficult perhaps it would be possible to save mails somewhere local / delete the temp file only after the mail has been confirmed sent / at least display an obvious banner warning that aerc is dead walking even though the user is composing a mail and give them the opportunity to manually save it somewhere.

~labrat 4 months ago

You'll be relieved to hear that I did just that 3 days ago https://git.labrat.space/aerc/commit/commands/compose/send.go?id=67923707ffd826ad1d02c0a5b5ebd75ffbc71364

Naturally this is only on the master branch for testing purposes but I didn't get any feedback so far and it's hard to tell whether that's bug free and ready to be released.

As for the graceful reconnection, that ticket is open and an outline how to approach this specified. Send a patch?

~fourstepper a month ago

did it ever make to the master branch labrat?

Register here or Log in to comment, or comment via email.