Machine.py; more consistent style

Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
This commit is contained in:
Nicolas Sebrecht 2015-01-10 02:21:07 +01:00
parent bd0461a986
commit f2010cdfb0

View File

@ -96,7 +96,7 @@ class MachineUI(UIBase):
s._printData(s.logger.info, 'acctdone', accountname) s._printData(s.logger.info, 'acctdone', accountname)
def validityproblem(s, folder): def validityproblem(s, folder):
s._printData(s.logger.warning, 'validityproblem', "%s\n%s\n%s\n%s" % \ s._printData(s.logger.warning, 'validityproblem', "%s\n%s\n%s\n%s"%
(folder.getname(), folder.getrepository().getname(), (folder.getname(), folder.getrepository().getname(),
folder.get_saveduidvalidity(), folder.get_uidvalidity())) folder.get_saveduidvalidity(), folder.get_uidvalidity()))
@ -108,7 +108,7 @@ class MachineUI(UIBase):
s.getnicename(destrepos))) s.getnicename(destrepos)))
def syncingfolder(s, srcrepos, srcfolder, destrepos, destfolder): def syncingfolder(s, srcrepos, srcfolder, destrepos, destfolder):
s._printData(s.logger.info, 'syncingfolder', "%s\n%s\n%s\n%s\n" % \ s._printData(s.logger.info, 'syncingfolder', "%s\n%s\n%s\n%s\n"%
(s.getnicename(srcrepos), srcfolder.getname(), (s.getnicename(srcrepos), srcfolder.getname(),
s.getnicename(destrepos), destfolder.getname())) s.getnicename(destrepos), destfolder.getname()))
@ -117,16 +117,16 @@ class MachineUI(UIBase):
folder.getvisiblename())) folder.getvisiblename()))
def messagelistloaded(s, repos, folder, count): def messagelistloaded(s, repos, folder, count):
s._printData(s.logger.info, 'messagelistloaded', "%s\n%s\n%d" % \ s._printData(s.logger.info, 'messagelistloaded', "%s\n%s\n%d"%
(s.getnicename(repos), folder.getname(), count)) (s.getnicename(repos), folder.getname(), count))
def syncingmessages(s, sr, sf, dr, df): def syncingmessages(s, sr, sf, dr, df):
s._printData(s.logger.info, 'syncingmessages', "%s\n%s\n%s\n%s\n" % \ s._printData(s.logger.info, 'syncingmessages', "%s\n%s\n%s\n%s\n"%
(s.getnicename(sr), sf.getname(), s.getnicename(dr), (s.getnicename(sr), sf.getname(), s.getnicename(dr),
df.getname())) df.getname()))
def copyingmessage(s, uid, num, num_to_copy, srcfolder, destfolder): def copyingmessage(s, uid, num, num_to_copy, srcfolder, destfolder):
s._printData(s.logger.info, 'copyingmessage', "%d\n%s\n%s\n%s[%s]" % \ s._printData(s.logger.info, 'copyingmessage', "%d\n%s\n%s\n%s[%s]"%
(uid, s.getnicename(srcfolder), srcfolder.getname(), (uid, s.getnicename(srcfolder), srcfolder.getname(),
s.getnicename(destfolder), destfolder)) s.getnicename(destfolder), destfolder))
@ -151,7 +151,7 @@ class MachineUI(UIBase):
dest)) dest))
def threadException(s, thread): def threadException(s, thread):
s._printData(s.logger.warning, 'threadException', "%s\n%s" % \ s._printData(s.logger.warning, 'threadException', "%s\n%s"%
(thread.getName(), s.getThreadExceptionString(thread))) (thread.getName(), s.getThreadExceptionString(thread)))
s.delThreadDebugLog(thread) s.delThreadDebugLog(thread)
s.terminate(100) s.terminate(100)