[PATCH] remove unneeded includes from syncmaster.py

Sebastian Spaeth Sebastian at SSpaeth.de
Wed Dec 1 15:13:15 GMT 2010

Signed-off-by: Sebastian Spaeth <Sebastian at SSpaeth.de>
One more easy fry: unneeded imports. Patch against current master.
The last 4 patches against current master are also pullable from 
the feature/code-simplification branch of 
git at github.com:spaetz/offlineimap.git

 offlineimap/syncmaster.py |   14 ++++----------
 1 files changed, 4 insertions(+), 10 deletions(-)

diff --git a/offlineimap/syncmaster.py b/offlineimap/syncmaster.py
index 8121416..2da8e3e 100644
--- a/offlineimap/syncmaster.py
+++ b/offlineimap/syncmaster.py
@@ -16,15 +16,10 @@
 #    along with this program; if not, write to the Free Software
 #    Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA
-import imaplib
-from offlineimap import imapserver, repository, folder, mbnames, threadutil, version
-from offlineimap.threadutil import InstanceLimitedThread, ExitNotifyThread
-import offlineimap.accounts
+from offlineimap import mbnames
+from offlineimap.threadutil import threadlist, InstanceLimitedThread, ExitNotifyThread
 from offlineimap.accounts import SyncableAccount, SigListener
-from offlineimap.ui import UIBase
-import re, os, os.path, offlineimap, sys
-from ConfigParser import ConfigParser
-from threading import *
+from threading import currentThread
 def syncaccount(threads, config, accountname, siglisteners):
     account = SyncableAccount(config, accountname)
@@ -41,8 +36,7 @@ def syncaccount(threads, config, accountname, siglisteners):
 def syncitall(accounts, config, siglisteners):
-    ui = UIBase.getglobalui()
-    threads = threadutil.threadlist()
+    threads = threadlist()
     mbnames.init(config, accounts)
     for accountname in accounts:
         syncaccount(threads, config, accountname, siglisteners)

More information about the OfflineIMAP-project mailing list