🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: linux.debian.bugs.dist
1 messages
1 total messages Started by Amin Bandali Thu, 26 Nov 2026 16:30
Bug#1155451: Connection error after configuring account
#6322
Author: Amin Bandali
Date: Thu, 26 Nov 2026 16:30
67 lines
3625 bytes
--=-=-=
Content-Type: text/plain

Package: ayatana-webmail
Severity: important
Tags: patch

After a fresh install of ayatana-webmail and configuring an account,
a 'Connection error' notification like the following is displayed and
the application exits:

    Unable to connect to account "foo@example.org",
    the application will now exit.

Debugging this, it turned out to be a side-effect of the packaging
patch for using Debian's python3-imaplib2 rather than the package's
vendored version of it: the system package (and indeed the upstream
imaplib2) does not have a LOGOUT symbol, and application.py's
Connection.isOpen() method's attempts to use imaplib.LOGOUT triggers
an exception that results in the application exiting.

The fix is simple: replace imaplib.LOGOUT with 'LOGOUT' directly.
The attached patch against the packaging repo applies this fix.

Best,
amin


--=-=-=
Content-Type: text/x-diff
Content-Disposition: attachment;
 filename=0001-Fix-Connection-error-after-account-setup.patch

From 59d7930659f9c68cfa372de1fce95cd9c3495977 Mon Sep 17 00:00:00 2001
From: Amin Bandali <bandali@debian.org>
Date: Thu, 26 Nov 2026 11:10:14 -0500
Subject: [PATCH] Fix 'Connection error' after account setup

---
 debian/patches/2001_use-Debians-imaplib2-module.patch | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/debian/patches/2001_use-Debians-imaplib2-module.patch b/debian/patches/2001_use-Debians-imaplib2-module.patch
index 78211c5..2485f29 100644
--- a/debian/patches/2001_use-Debians-imaplib2-module.patch
+++ b/debian/patches/2001_use-Debians-imaplib2-module.patch
@@ -13,6 +13,15 @@ Forwarded: https://github.com/AyatanaIndicators/ayatana-webmail/issues/14
  import os.path
  import os
  import urllib3
+@@ -448,7 +448,7 @@
+ 
+     def isOpen(self):
+ 
+-        return checkNetwork() and self.oImap and self.oImap.state != imaplib.LOGOUT and not self.oImap.Terminate
++        return checkNetwork() and self.oImap and self.oImap.state != 'LOGOUT' and not self.oImap.Terminate
+ 
+ class Message(object):
+ 
 --- a/ayatanawebmail/dialog.py
 +++ b/ayatanawebmail/dialog.py
 @@ -5,7 +5,7 @@
-- 
2.47.3


--=-=-=--
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads