Reformat offlineimap/threadutil.py

Add some spaces, remove lines,... now format is better (lintian).
This commit is contained in:
Rodolfo García Peñas (kix) 2020-08-29 20:22:53 +02:00
parent 973e3324ff
commit 74ae944b06

View File

@ -20,12 +20,11 @@ from queue import Queue, Empty
import traceback
from offlineimap.ui import getglobalui
STOP_MONITOR = 'STOP_MONITOR'
######################################################################
# General utilities
######################################################################
def semaphorereset(semaphore, originalstate):
"""Block until `semaphore` gets back to its original state, ie all acquired
@ -37,6 +36,7 @@ def semaphorereset(semaphore, originalstate):
for i in range(originalstate):
semaphore.release()
class accountThreads(object):
"""Store the list of all threads in the software so it can be used to find out
what's running and what's not."""
@ -73,6 +73,7 @@ class accountThreads(object):
exitedThreads = Queue()
def monitor():
"""An infinite "monitoring" loop watching for finished ExitNotifyThread's.
@ -189,6 +190,7 @@ class ExitNotifyThread(Thread):
limitedNamespaces = {}
def initInstanceLimit(limitNamespace, instancemax):
"""Initialize the instance-limited thread implementation.